Component not loading first run

Product: PowerShell Universal
Version: 1.4.6
UniversalDashboard: 3.3.3

Everytime i do an update to my PowerShell Universal environment, on the first run, the Style Component is not loaded.

-Component @(“UniversalDashboard.Style:1.0.0”)

The above is part of the dashboards.ps1 file.
We runt it as a service, with the built in Kestrel web server.
We deploy each new version through Azure DevOps, which downloads the latest version (.zip file), extracts it, stops the service, copies the files and then starts the service again.

Every time this is done, we get error messages that New-UDStyle is not recognized.
I then have to remove “-Component @(“UniversalDashboard.Style:1.0.0”)” from the dashboards.ps1 file. Restart the service, then go in and add the Component again through the admin interface and restart the dashboard.

Do anyone have any idea why i have to do this every time I release a new version?

Any help appriciated!

When PSU first starts up, it deploys dashboard frameworks and components asynchronously to a deployment directory. At the same time, it’s also starting the dashboard.

This is a logic bug that we need to resolve. You can work around this by adding an import-module directly into your dashboard to load the UDStyle component library from the installation directory.

I really think we should just include UDStyle with the dashboard framework. It’s such a useful component

Ah, then I’ll just add it to the dashboard file for now, but it would be great, as you say, to add it directly to the framework!