QmlWeb-based QML viewer
This is a QmlWeb-based GUI viewer for *.qml
files.
This is not a replacement to Qt QML by any means and should not be used in production.
The only purpose of this tool is to test QmlWeb and visually compare the rendered
results with Qt QML output (e.g. qmlscene
).
Installation and usage
Prerequisites
You need Node.js with npm to install and run qmlweb-viewer.
See Installing Node.js via package manager or Node Version Manager for more detailed instructions on that.
Local install (to a subdirectory):
npm i qmlweb-viewer./node_modules/.bin/qmlweb-viewer path-to-file.qml
This way, qmlweb-viewer
will be installed into the node_modules
subdirectory.
Global install
See Fixing npm permissions
to fix permissions issues, running npm
as root is not recommended.
npm install -g qmlweb-viewerqmlweb-viewer path-to-file.qml
This way, you can use qmlweb-viewer
from any directory, it will be added into
your PATH
.
Debugging
Launch with the --debug
flag, e.g. qmlweb-viewer --debug path-to-file.qml
to open a Developer Tools window alongside with your QML file.
Using with a development version of QmlWeb
To use with QmlWeb from the master
branch (or any other non-release version),
follow the installation steps, then remove the
./node_modules/qmlweb/lib
directory and replace it with a symlink to a ./lib
directory of your development QmlWeb version.
License
QmlWeb-Viewer is licensed under the MIT license, see LICENSE.