2015-10-22 08:31:52 +01:00
|
|
|
# node
|
2014-03-05 20:37:38 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
> Server-side JavaScript platform (Node.js).
|
2019-01-30 11:51:51 +00:00
|
|
|
> Homepage: <https://nodejs.org>.
|
2014-03-05 20:37:38 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Run a JavaScript file:
|
2015-12-25 22:17:46 +00:00
|
|
|
|
|
|
|
`node {{file}}.js`
|
|
|
|
|
2016-02-28 20:09:02 +00:00
|
|
|
- Start a REPL (interactive shell):
|
2014-03-05 20:37:38 +00:00
|
|
|
|
|
|
|
`node`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Evaluate JavaScript by passing it in the command:
|
2014-03-05 20:37:38 +00:00
|
|
|
|
2015-12-25 22:17:46 +00:00
|
|
|
`node -e "{{code}}"`
|
2019-01-11 00:35:23 +00:00
|
|
|
|
|
|
|
- Evaluate and print result, useful to see node's dependencies versions:
|
|
|
|
|
|
|
|
`node -p "{{process.versions}}"`
|