UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    How to run WebAssembly in click package (html template)

    Scheduled Pinned Locked Moved App Development
    1 Posts 1 Posters 188 Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • ? Offline
        A Former User
        last edited by

        I have a question regarding Web Assembly. I was trying to see whether I can compile the content of https://www.egui.rs/ to Web Assembly and run it on my UT device. As a first step, I followed roughly the steps described in https://github.com/emilk/egui/blob/master/egui_demo_app/README.md (serving from a libertine container using python, and navigating to the content with the Morph browser). That worked fine, I can copy the files that I compiled on my desktop computer on my phone and run them.

        Then I tried to package the content in a click app. For this, I created a new app using "clickable new" and selected the html template. I copied all the files from above to the "www" folder. Clickable generates the click package without a problem. But when I run the app on my phone, I get an error: "Make sure you use a modern browser with WebGL and WASM enabled."
        Can you help me understand why the first approach works, but the second one does not? Is this a fundamental limitation of click packages vs. the Morph browser, or am I just missing some settings in my clickable project?

        I'm interested in this, because I think if that works, I can create applications for use on my desktop and tablet, but also on the phone while using mostly the exact same codebase. I think that would be very handy, as the library comes with touch/multitouch support also.

        1 Reply Last reply Reply Quote 0
        • First post
          Last post