COver graphics_NodeJS

Node.js Cheat Sheet

Alex Alykiotis
English

About

Node.js is a server-side JavaScript runtime that makes it easy to build fast, scalable network applications. Many enterprise companies have adopted Node.js because of its event-driven, non-blocking I/O model, which makes it lightweight and efficient.

This Node.js cheat sheet helps developers master the most useful command-line flags to customize Node.js’s behavior. You’ll save time and energy looking up how to do everyday development tasks like executing scripts, debugging, and monitoring your Node.js applications.

Download the Node.js cheat sheet and learn how to:

  • Perform JavaScript syntax checks.
  • Quickly test code with the Node.js (Read-Eval-Print-Loop).
  • Require specific modules at startup.
  • Automatically detect deprecated APIs and trace warnings.
  • Catch production problems like slow performance and memory leaks with diagnostic reports.
  • Investigate Node.js process memory use with the garbage collector and heap snapshots.
  • Collect CPU metrics to understand Node.js application performance.
  • Initialize the built-in debugger to troubleshoot Node.js applications and scripts.

With Red Hat Developer cheat sheets, you get essential information right at your fingertips so you can work faster and smarter. Easily learn new technologies and coding concepts and quickly find the answers you need.

Excerpt

-v, --version: Prints the current version of Node.js you use

-e, --eval: Evaluates the current argument as JavaScript

-c, --check: Checks the syntax of a script without executing it

-i, --interactive: Opens the Node.js REPL (Read-Eval-Print-Loop)

-r, --require: Pre-loads a specific module at startup

Related Cheat sheets