I\'m looking for a way to write some simple scripts in javascript, like I would in ruby. For example, I might write a script like:
var str = \"Hello World\"
With Phantom JS you can easily run a javascript from command line and it naively supports DOM, CSS Selector and JSON.