qt_add_qml_module() is an awesome CMake function introduced in Qt 6.2 that streamlines various aspects of organizing QML modules. However, we had a feeling that there are not many examples and demos out there that were showing more than just a very basic case.
Therefore we created a demo application that facilates this CMake blessing. Currently implemented cases:
- Main module with files in subfolders
- Three extra modules inspiring for better QML files structuring
- Adding singleton QML types to the QML module
- Adding JavaScript files to the QML module
- Adding resources to the QML module
- Adding dependencies to the QML module
- Marking specific files in the module as private
- Adding C++ registered QML type to QML module
Watch our Qt World Summit 2022 presentation on using qt_add_qml_module() function: PLACE_LINK_HERE See the blog post with the explanation: PLACE_LINK_HERE
Project was built against Qt 6.4
We’re a team of Qt and C++ enthusiasts dedicated to helping businesses build great cross-platform applications. As an official Qt Service Partner, we’ve earned the trust of companies across various industries by delivering high-quality, reliable solutions. With years of experience in Qt and QML development, we know how to turn ambitious ideas into outstanding products.
![]() |
![]() |
![]() |
![]() |
We offer a wide range of services—from brainstorming ideas to delivering polished applications—always tailored to our clients’ needs. By combining deep knowledge of Qt modules and modern technologies with a practical, cost-effective approach, we create solutions that truly make a difference.
Need help with anything? We’ve got you covered. Our professional support services are here to assist you with. For more details about support options and pricing, just drop us a line at https://somcosoftware.com/en/contact.
Check out those links if you want to see Somco Software in action and follow the newest trends saying about Qt Qml development.