[removed] Standalone compiler or interpreter for Windows?

前端 未结 9 735
半阙折子戏
半阙折子戏 2021-02-05 18:19

What are the JavaScript compilers or interpreters available for Windows?

I read the book Eloquent JavaScript recently.

相关标签:
9条回答
  • 2021-02-05 18:33

    Perhaps a bit convoluted for what you're looking for but you can use Rhino's JavaScript Compiler to compile JavaScript source code into Java class files which can then be compiled to binary executable programs using the standard GCJ frontend to the GCC compiler suite.

    As mentioned by others, the JScript implementation of ECMAScript is available by default on modern Windows installations. Files with a ".js" extension can be double-click executed or run on the command-line using the cscript.exe command.

    0 讨论(0)
  • 2021-02-05 18:37

    jsdb is nice. I use it within editplus, sometimes within Aptana Studio

    0 讨论(0)
  • 2021-02-05 18:39

    You can also, under some circumstances run JScript scripts (Microsoft's Javascript implementation) directly on the command prompt.

    But my personal favourite is Rhino, mentioned in the other answer.

    0 讨论(0)
  • 2021-02-05 18:42

    Ok, Windows Scripting Host is tool for performing various administrative tasks using Microsoft's Active Scripting and can run scripts in various languages, including JScript, their ECMAScript implementation. There is no much else to say about it, so point your browser to the reference - http://msdn.microsoft.com/en-us/library/shzd7dy4(VS.85).aspx

    Forget about compiler, BTW, ECMAScript is interpreted language (JIT compiling is the other issue)

    Also, note that ECMAScript standard does not define any standard I/O, so the host program is responsible for providing it.

    0 讨论(0)
  • 2021-02-05 18:43

    There are several free standalone Javascript interpreters available:

    1. V8 - This is the same Javascript engine used in the Chrome browser.
    2. SpiderMonkey - From Mozilla.
    3. Rhino - A Javascript implementation on Java.
    0 讨论(0)
  • 2021-02-05 18:48

    Node.js works well as an interpreter, even if you do not choose to use it for web applications. It is a framework that runs on the V8 JavaScript engine. It is well documented with a large selection of official and third party modules.

    It does require cygwin to run on Windows though (or you can compile it with MingW). There are precompiled binaries, including the required cygwin libraries, available at node-js.prcn.co.cc.

    0 讨论(0)
提交回复
热议问题