Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

webassembly XmlListModel not working



  • Hello,
    I have test program, I work fine in normal desktop.
    When I complile it with webassembly, XmlListModel not load data.
    In console I see :
    qml: XML Status change 2 error:

    So XmlListModel not go to state 1 (Ready state), I dont know why.
    In web browser I see query "http://127.0.0.1/text.xml" and good response (xml).

    What is wrong?
    Thank you

    Rectangle{
        XmlListModel {
            id: xmlModel
           source: "http://127.0.0.1/text.xml"
            query: "/cross/cros"
            XmlRole { name: "time";        query: "@time/string()" }
            onStatusChanged: {
                console.log("XML Status change "+status+" error:"+errorString())
            }
        }
    
    
        ListView {
            id:view
            anchors.fill: parent
            model: xmlModel
            delegate: Text {
                text: time
            }
        }
    }
    
    

Log in to reply