Node.js (commonly called "Node") is a server side JavaScript engine. You can download it and read about it at

I use it to develop the JavaScript I use in web pages or to write programs just like shell scripts or any other type of programming language. For instance, I used it to develop the code in How Do I Get Query String Values in JavaScript?

I just download Node.js and use it in the shell by invoking: "node". In some installations the command is "nodejs". This runs a special program called "REPL" which allows you to write interactive JavaScript, similar to how you'd do it in the browser's console.

Here's an example session:

> function queryStringToObj() {
...     var q = window.location.href;
...     var a = q.split('?')[1].split('&');
...     var o = {};
...     for(var i in a) {
.....         var pair = a[i].split('=');
.....         o[pair[0]] = pair[1];
.....     }
...     return o;
... }
> qs = queryStringToObj();
{ foo: 'bar', yes: undefined }
> .load utils.js

Notice that you can just type the variable name and it's value is returned.

You can load JavaScript programs using the .load command. Other commands are also available.

This looks simple enough, however be aware, everything in Node.js is asynchronous. That means you cannot write a simple method to read a file and operate on it. Instead, you must handle the data retrieved in a callback handler. If you aren't familiar with reactive programming, you'll need to learn.

In short, Node.js is a powerful and efficient engine for just about any project, if you haven't tried it, it's worth a peek.