A commonly asked question for people starting with programming is "How can I run my application on another computer?" It would be cool to have a template that adds a dist/package command that creates a Flatpak (https://github.com/flatpak/qt-flatpak-demo), an AppImage or something else which is easy to use.
I agree, and it should be relatively simple to implement a flatpak build since Qt already provides QJsonDocument/QJsonObject and other classes that are pretty simple to use, and KDE already uses Json for everything flatpak. I don't think appimage/snap would be as easy to implement. For comparison, GNOME's IDE, GNOME Builder integrates with flatpak builds. I might be able to work on this in the following months.
Actually, now that I searched further, KDevelop *already* has support for flatpak templates, I dunno how I missed it. The only means to build it from within KDevelop seems to be via External scripts, though.