1

Possible Duplicate:
Running V8 Javascript Engine Standalone

I want to try a standalone JavaScript interpreter, rather than executing in Firefox all the time. I did find spidermonkey by googling, which could be installed on ubuntu, but is there a way to use Google's v8 as a standalone interpreter?

Community
  • 1
  • 1
Rahul
  • 11,129
  • 17
  • 63
  • 76

5 Answers5

5

Yup yup yup! You can download the V8 shell from Google and run it on its own:

http://code.google.com/apis/v8/build.html

mattbasta
  • 13,492
  • 9
  • 47
  • 68
2

Not only can you run V8 standalone, there is a great project called node.js that adds some very useful libraries.

Neall
  • 26,428
  • 5
  • 49
  • 48
1

edit: misread your question. Sorry xD, take a look at this post instead: Running V8 Javascript Engine Standalone

There you'll find instructions on how to build the interpreter.

Community
  • 1
  • 1
salezica
  • 74,081
  • 25
  • 105
  • 166
  • Yeah, I know, I realized my answer had nothing to do with the question right after clicking send =P edited it a second later. – salezica Oct 13 '10 at 14:12
  • Your link is to an answer about Python. – Matt Ball Oct 13 '10 at 14:13
  • LOL. Fixed. I don't know where my head is. Thanks for spotting that, I would've walked away thinking I might've helped someone. – salezica Oct 13 '10 at 14:15
  • Well i finally installed and it worked .. but there are many things that work in the browser but not in this standalone interpreter For example , the alert(" test") function , it works fine in browser , but not in this standalone one .. am i missing on something here ? – Rahul Oct 13 '10 at 15:09
1

Yes, v8 can run standalone. http://code.google.com/p/v8/

Detailed instructions for building v8 on Windows: http://code.google.com/p/v8/wiki/BuildingOnWindows

Matt Ball
  • 354,903
  • 100
  • 647
  • 710
0

If you install node.js it gives you command line access to V8 (sans DOM)

Edit: Node ppa

xj9
  • 3,381
  • 2
  • 24
  • 23