konsoletyper / teavm

Compiles Java bytecode to JavaScript, WebAssembly and C
https://teavm.org
Apache License 2.0
2.55k stars 262 forks source link

Add option to generate auto-running module #788

Open konsoletyper opened 8 months ago

konsoletyper commented 8 months ago

TeaVM produces JS and WebAssembly modules that don't run actual main method, but export main function that a user should call. Although it's enough for all practical cases, for some small scripts it's easier to have TeaVM auto-run everything, and all user needs is to just include script.