Is there currently an "offline" client-side only deployment option for an Uno platfom WASM app?

Viewed 138

After viewing the showcases at the Uno Platform website...Can I produce a single file or package that my user base can download and launch without the need to browse to an endpoint every time or futz with security setting on their web browser? Currently I'm unable to "just run" what Visual Studio "publishes to folder", I'm guessing because of CORS issues?

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at file:///.../Releases/WASM/dotnet.wasm. (Reason: CORS request not http).

The last time I attempted to find an easily repeatable production way around CORS I just gave up and went native, if someone knows of one I'll take that as an answer, but the best I've found is something "like" Electron? Is there something like Electron for a Uno WASM app?

1 Answers

You could suggest to your users that they install the WASM head as a PWA? Nick Randolph describes how to do it here: https://nicksnettravels.builttoroam.com/uno-as-a-pwa/

Obviously this will depend on you having deployed your WASM app to a web server somewhere. Nick also has a great article on deploying the WASM app to (practically free) Azure Blob Storage which you can find here: https://nicksnettravels.builttoroam.com/post-2019-03-20-deploying-uno-wasm-using-blob-storage-aspx/ (FYI, all the deployment issues he encountered have been resolved and now the deployment, "just works").

Related