How to Cross-Compile Java Source Code to JavaScript?

后端 未结 7 1475
醉酒成梦
醉酒成梦 2020-12-12 19:02

Given a set of Java source code files, how can I compile them into one or more JavaScript files that can be used with hand-crafted JavaScript?

GWT is one option, but

7条回答
  •  一整个雨季
    2020-12-12 19:38

    While the question is about compiling Java sources to JavaScript I think it's worth mentioning that there is TeaVM which compiles Java bytecode to JavaScript. I have never tried it, but it seems very promising.

提交回复
热议问题