Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Javascript interpreter to replace Python

Tags:

In terms of quick dynamically typed languages, I'm really starting to like Javascript, as I use it a lot for web projects, especially because it uses the same syntax as Actionscript (flash).

It would be an ideal language for shell scripting, making it easier to move code from the front and back end of a site, and less of the strange syntax of python.

Is there a good, javascript interpreter that is easy to install (I know there's one based on java, but that would mean installing all the java stuff to use),

like image 227
Matthias Wandel Avatar asked Sep 21 '08 20:09

Matthias Wandel


People also ask

Can JavaScript replace Python?

1 Answer. No, Python cannot replace JavaScript because: (FRONT-END)JavaScript is browser-native and Python is not.

CAN node replace Python?

No, because Node. js works with JavaScript, and Python has CPython.

What can you do with Python that you can't do with JavaScript?

While Python can be used to develop the back-end part of a web application, JavaScript can be used to develop both the back-end and the front-end of the application. The front-end is the part of the application that the user sees and interacts with.

Is Brython a framework?

There is no framework available in Brython. It may take many years for Brython to be used on client-side. There is a lack of resources to learn Brython, so people are choosing Javascript over Brython.


1 Answers

I personally use SpiderMonkey, but here's an extensive list of ECMAScript shells

Example spidermonkey install and use on Ubuntu:

$ sudo apt-get install spidermonkey $ js myfile.js output $ js js> var f = function(){}; js> f(); 
like image 160
Zach Avatar answered Sep 27 '22 19:09

Zach