It's almost too simple for a standalone example. First follow the getting 
Electron Quick Start guide 
(https://www.electronjs.org/docs/latest/tutorial/quick-start)  until you 
get to the point where an "npm start" gives you an Electron window with the 
"Hello World" message.

Next you need the three output files (.html, .js, wasm) from an Emscripten 
build, let's call them c64.html, c64.wasm and c64.js - you can download 
examples from here:

https://raw.githubusercontent.com/floooh/tiny8bit/master/c64.html
https://raw.githubusercontent.com/floooh/tiny8bit/master/c64.wasm
https://raw.githubusercontent.com/floooh/tiny8bit/master/c64.js

Put those files into the project root directory where the index.html file 
is.

Next, in the main.js file, where the index.html is loaded, replace 
index.html with c64.html:

win.loadFile('c64.html');

Next, run 'npm start'. VoilĂ , C64 emulator in Electron ;)

[image: Screenshot 2022-06-24 at 16.53.54.png]

On Wednesday, 22 June 2022 at 22:17:20 UTC+2 TH wrote:

> I am looking for an example of using a Vendor created Emscription js glue 
> file and wasm file in Electron. I am fairly new to Electron Dev and I have 
> not been able to find any recent  examples. Any help would be appreciated. 
> Thanks. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/emscripten-discuss/2963304c-9d7b-4542-8107-a4c6361eb87an%40googlegroups.com.

Reply via email to