Rhino和Spidermonkey JavaScript引擎有什么区别? [英] What is the difference between Rhino and Spidermonkey JavaScript engines?

查看:193
本文介绍了Rhino和Spidermonkey JavaScript引擎有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我第一次开始学习Javascript,但是一开始我坚持两种可能的选择:Rhino和Spidermonkey。请问,请告诉我一个是什么,另一个是什么,所以我可以轻松地为自己选择最适合我需求的选择。如果它对你来说更容易,你可以列出两个Javascript版本的优点和缺点。

For the first time, I began learning Javascript, however on the start I stuck up with two possible options: Rhino and Spidermonkey. Could you please, tell me what is one, and what is another, so I can easily choose for myself the best option that suits my needs. If it makes easier for you, you can list advantages and disadvantages of both Javascript versions.

推荐答案

这取决于你是什么尝试使用JavaScript。如果您的目的只是学习该语言,那么我建议您使用Chrome或Firefox等网络浏览器,并使用其内置(或插件)JavaScript控制台。

It depends on what you're trying to do with JavaScript. If your intent is just to learn the language then I recommend using a web browser such as Chrome or Firefox and using their built-in (or addon) JavaScript consoles.

As关于独立JavaScript解释器的具体问题,这里有一些注意事项:

As to your specific question about standalone JavaScript interpreters, here are some notes:


  1. Rhino - 用Java实现,主要用作Java平台的脚本引擎扩展。包括一个交互式命令行控制台,有助于学习。

  2. SpiderMonkey - 用C / C ++实现,旨在用作Firefox中的JavaScript引擎。

  1. Rhino - implemented in Java, intended primarily for use as a scripting engine extension for the Java platform. Includes an interactive command-line console, which will be helpful for learning.
  2. SpiderMonkey - implemented in C/C++, intended for use as the JavaScript engine in Firefox.

参见:


  1. V8 - 用C ++实现,主要设计为Chrome浏览器的JavaScript实现;非常适合嵌入。

  2. node.js - 一个独立的,即兴的,异步的JavaScript环境,基于V8。

  3. 独角鲸 - 一个CommonJS平台。

  4. Windows脚本主机 - 包括一个JScript解释器(基于ECMAScript,与现代JavaScript非常相似)。

  1. V8 - implemented in C++, designed primarily as the Chrome browser's JavaScript implementation; well suited for embedding.
  2. node.js - a standalone, evented, asynchronous JavaScript environment, based on V8.
  3. Narwhal - a CommonJS platform.
  4. Windows Script Host - includes a JScript interpreter (ECMAScript based, very similar to modern JavaScript).

这篇关于Rhino和Spidermonkey JavaScript引擎有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆