3

I used emscripten to generate some html/js/wasm/data files and would like to add that as a page to my (Wordpress) website. Is this possible? If so, how?

4
  • It just generates some .html and .js files? If you want to embed this into an existing page then you could write a short plugin that contains the files and defines a shortcode to emit the HTML and [enqueue]() the JavaScript; if you want to include the generated HTML as a page as-is then you could create a specific template in your theme for the page by slug and just put the HTML in there.
    – Rup
    Commented Aug 5, 2020 at 15:02
  • @Rup Thanks for the advice. I can limit it to just HTML and Javascript, but it would be much slower than if I used the WebAssembly and data files.
    – cajomar
    Commented Aug 6, 2020 at 14:01
  • Right, sorry, I don’t know enscripten. You can include any files you want, yes, but you’d need to wire it up with HTML and JS I’d imagine?
    – Rup
    Commented Aug 6, 2020 at 14:02
  • @Rup Right; the HTML calls the JS which runs the WASM and loads the .data, at least that's my understanding of it.
    – cajomar
    Commented Aug 6, 2020 at 14:19

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.