As we discussed in the Plasma spring, we might get a different applet loading mechanism once applets with precompiled QML can be loaded. This means that the KPackage usage, which is currently part of the public methods and also publicly linked makes such change harder.
For the applets, we no longer need to access the kapckage to get the plugin's metadata, because the applet can simply not embed json metadata and will then get the metadata from kpackage passed to at runtime.
Also, we should get rid of the public KPackage linking, because most plasma-frameworks consumers do not need kpackage directly.
For doing this, we need to rewrite the plasma_install_applet CMake macro. In KF6, we do not need the json conversion logic that the kpackage macro currently has.