QML Loader implementation guide its source when changing context property in Qt 6.5
I've been working on this all day and I keep running into I need help solving I'm working with an scenario where a QML Loader component does not update its source properly when the context property it relies on changes... I have a `Loader` that loads different components based on a property that gets updated on a button click. However, after the initial load, subsequent changes to this property do not reflect in the UI.\n\nHere's the relevant part of my QML code: \n```qml\nimport QtQuick 2.15\nimport QtQuick.Controls 2.15\n\nApplicationWindow {\n visible: true\n width: 400\n height: 300\n\n property string currentPage: "Page1"\n\n Loader {\n id: mainLoader\n source: currentPage\n }\n\n Button {\n text: "Load Page 2"\n onClicked: {\n currentPage = "Page2"; // This doesn't trigger a reload\n }\n }\n}\n```\n\nIn my `Page2.qml` file, I have a simple Text element that should show a different message, but it remains blank after the first load. I’ve even tried adding `Item {}` as a splash screen to debug, and it still doesn't load the new page content. \n\nOne thing I noticed is that when I log `currentPage` after the button click, it logs the new value correctly, but the Loader does not seem to react to these changes. I also tried using a `Connections` object to listen for changes, but it still doesn't work. \n\nDoes anyone have experience with QML Loaders and how to ensure they update their source correctly? Am I missing something with how QML handles property changes?\n\nThanks in advance for your help! This is for a CLI tool running on Ubuntu 22.04. Any ideas how to fix this? Is there a better approach? I'm working with Qml in a Docker container on CentOS. Is this even possible?