Nodeclipse / nodeclipse

Nodeclipse-1 : Eclipse plugin for Node.js, PhantomJS development (Nodeclipse core plugin); Maven and Gradle (with Android) plugins
https://nodeclipse.github.io/
158 stars 78 forks source link

[idea] option Run as -> `node -p` for selection in Editor #82

Open paulvi opened 10 years ago

paulvi commented 10 years ago

Node has options for evaluating passed string

 -e, --eval script    evaluate script
  -p, --print          evaluate script and print result

e.g. node -e "console.log('Version: ' + process.version)"

or

$ node -p "process.version"
v0.10.0

Idea is to Run as -> node -p for selection in Editor