https://github.com/ksxnodeapps/eval-to-json
Evaluate a JavaScript expression and print JSON output
https://github.com/ksxnodeapps/eval-to-json
cli eval javascript json nodejs npm
Last synced: about 2 months ago
JSON representation
Evaluate a JavaScript expression and print JSON output
- Host: GitHub
- URL: https://github.com/ksxnodeapps/eval-to-json
- Owner: ksxnodeapps
- License: mit
- Created: 2017-04-08T15:07:06.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-01-23T09:46:50.000Z (over 8 years ago)
- Last Synced: 2025-09-17T19:55:23.803Z (9 months ago)
- Topics: cli, eval, javascript, json, nodejs, npm
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/eval-to-json
- Size: 26.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# eval-to-json
Evaluate a JavaScript expression and print JSON output
## Installation
```bash
npm install --global eval-to-json
```
## Command-line usage
```bash
eval-to-json file.js
```
```bash
eval-to-json < file.js
```
```bash
cat file.js | require-to-json
```
```bash
echo '9 * 87 * 654 * 3210' | eval-to-json
```