Skip to content

ksxnodeapps/eval-to-json

Repository files navigation

eval-to-json

Evaluate a JavaScript expression and print JSON output

Installation

npm install --global eval-to-json

Command-line usage

eval-to-json file.js
eval-to-json < file.js
cat file.js | require-to-json
echo '9 * 87 * 654 * 3210' | eval-to-json