I just tried an old example of mine from early 2020 (with updated HaxeUI, the old versions no longer compile), and unfortunately I couldn’t make it work on Krom where it fails with error messages because it tries to access browser stuff (Krom is JS) that doesn’t exist in Krom. However, on Html5 and probably also Hashlink it works (after adding a workaround for a Haxe bug I found).
In general, the Kha backend of HaxeUI seems to have some problems, limited support for the CSS attributes that are supported by other backends, and HaxeUI seems to be a bit over-engineered sometimes (although you can do a lot with it, it’s a powerful library). But I haven’t used much of it, so I can’t tell you much about it. However, that was the reason why I wrote my own UI library a while ago. Zui was too limiting and HaxeUI too complex and error-prone.
As for websockets: if you’re on the Discord server, take a look at the #armory-dev channel, someone is currently implementing networking nodes with hxwebsockets. I’m not sure whether it works in Krom though.
Usually you don’t need to change any package headers. As long as a library is included in the build, you can import it as stated in its API. So
import haxe.ui.Toolkit for example should work without any problems as long as you correctly “installed” HaxeUI. If you have any specific errors then maybe create a new forum thread for them or ask on Discord.
Yes, the imports follow the directory structure, although I think it’s mostly by convention. If I’m not mistaken then you can choose the package of each module freely as long as it is also reflected in the corresponding import statements. I’m not sure what exactly you mean with “separate”, you mean that you want to do
import Toolkit instead of
import haxe.ui.Toolkit? How would you solve situations where two libraries have a
Toolkit module or class?