I might shelf wheatleaf and port wine to javascript like how fengari ported lua to javascript
It’s so simple! All you need to do is realize WINE runs programs natively, and just recreates the libraries that are available on windows. You just need to write a compiler to compile JS to x86, and then emulate an x86 processor, and then call it WIAE, for wine is an emulator.
The way wine works, is that it basically runs the exe on linux, as they are both x86, and it just converts windows syscalls to linux syscalls, and same for dlls.