A collection of useful NodeJS packages categorized and with short description.
💻 Frontend frameworks
Vue was built by combining the best approaches from React and others, focusing on features that made writing Web apps faster, easier, and more pleasant. Great documentation. Often used with Vue-router and Vuex.
🎨 Styling frameworks
World’s most popular framework for building responsive, mobile-first sites. Intuitive and powerful, tho relatively bulky in size. Many modern UI kits are based on it like React Bootstrap or Reactstrap.
A low-level, utility-first CSS framework for rapid UI development. Built from the ground-up to be super customizable.
CSS-in-JS tool that bridges the gap between components and styling, offering numerous features to get you up and running in styling components in a functional and reusable way.
🔲 Backend frameworks
Fast, unopinionated, minimalist web framework for Node.js. It is relatively minimal with many features available as plugins. Often referred to as a standard server framework for Node.js.
hapi was originally used for the Express framework. With hapi you can build powerful, scalable applications, with minimal overhead and full out-of-the-box functionality.
Sails is the most popular MVC framework for Node.js with support for the requirements of modern apps: data-driven APIs with a scalable, service-oriented architecture.
🔗 CORS and requests
Node.js middleware for providing a Connect/Express middleware that can be used to enable cross-origin resource sharing with various options.
A promise-based HTTP client for the browser and Node.js. It’s easy to set-up, intuitive, and simplifies a lot of stuff compared to JS built-in Fetch API.
Body parsing middleware, that extracts the entire body portion of an incoming request stream and exposes it on req.body as something easier to interface with.
🧩 API services
A Node.js web service framework optimized for building semantically correct RESTful web services ready for production use at scale. restify optimizes for introspection and performance.
A query language for APIs and a runtime for fulfilling those queries with your existing data. Provides a complete description of the data in your API, gives clients the power to ask for exactly what they need.
🤝 Web sockets
Socket.IO enables real-time, bidirectional, and event-based communication. It works on every platform, browser, or device, focusing equally on reliability and speed.
Simple to use, fast, and thoroughly tested WebSocket client and server implementation. A great, less abstract, and bare alternative to Socket.io.
Specifically, an HTTP request logger, storing HTTP requests and giving you concise insight into how your app is being used, and where there could be potential errors.
A logger for just about everything with support for multiple means of transport. Has been out there for longer than Morgan, it also has a bigger community of maintainers and more downloads.
💾 Database tools
Sequelize is a promise-based Node.js ORM for Postgres, MySQL, MariaDB, SQLite and Microsoft SQL Server. It features solid transaction support, relations, eager and lazy loading, read replication and more.
A batteries-included, multi-dialect (MSSQL, MySQL, PostgreSQL, SQLite3, Oracle (including Oracle Wallet Authentication)) query builder for Node.js.
Objection.js is an ORM for Node.js that aims to stay out of your way and make it as easy as possible to use the full power of SQL and the underlying database engine while still making the common stuff easy and enjoyable.
Objection.js is built on knex. All databases supported by knex are supported by objection.js.
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Mongoose supports both promises and callbacks.
🔓 Auth tools
Passport’s purpose is to authenticate requests through an extensible set of plugins known as strategies. You provide Passport a request to authenticate, and Passport provides hooks for controlling what occurs when authentication succeeds or fails.
A library to help you hash passwords.
bcrypt is a password-hashing function designed by Niels Provos and David Mazières, based on the Blowfish cipher and presented at USENIX in 1999.
JSON Web Tokens (JWT) are an open, industry-standard RFC 7519 method for representing claims securely between two parties. This package allows you to decode, verify, and generate JWT.
🔧 Config modules
Settings are stored in configuration files within your application and can be overridden and extended by environment variables, command line parameters, or external sources.
Zero-dependency module that loads environment variables from a
.env file into
📃 Static site generators
A modern site generator that creates fast, high-quality, dynamic React apps, from blogs to e-commerce sites to user dashboards. Great plugin ecosystem and templates.
NextJS first and foremost supports server rendering as well as statically generated content. You can also define serverless functions as API endpoints.
NuxtJS is basically a NextJS alternative in Vue’s ecosystem. NuxtJS’s goal is to make web development powerful and performant with great developer experience in mind.
🌟 Templating languages
Mustache is a logic-less template syntax. It can be used for HTML, config files, source code - anything. It works by expanding tags in a template using values provided in a hash or object.
Uses a template and an input object to generate HTML or other text formats. Handlebars templates look like a regular text with embedded Handlebars expressions. Handlebars is largely compatible with Mustache templates.
📷 Image processing
A great module to convert large images in common formats to smaller, web-friendly JPEG, PNG and WebP images of varying dimensions.
Dedicated module to ease work with cloud service that offers a solution to a web application’s entire image management pipeline.
📅 Date formatting
DayJS is a fast and lightweight alternative to MomentJS (in maintenance mode since September, 2020). Uses similar API - if you have used MomentJS, you already know how to use most of DayJS.
If you like another light-weight alternative, with a slightly different API, Luxon might be the right choice for you.
🧙♂️ Data generators
DEPRECATED Creates amazingly short non-sequential url-friendly unique IDs. Perfect for URL shorteners, DB IDs, and any other IDs.
Handy tiny package to quickly and easily generate more complex universally unique identifiers (UUIDs). It supports v1, v2, v3, v4 and v5 UUIDs.
Useful package for generating massive amounts of fake data in the browser and Node.js.
Handy library of string validators and sanitizers. Lots of useful methods available, like
📧 Forms and emails
Formik is a popular open-source form library for React and React Native. It’s easy to use, declarative, and adaptive.
Multer is a Node.js middleware for handling
multipart/form-data, which is primarily used for uploading files.
Nodemailer is a module for Node.js applications to allow easy email sending. The project got started back in 2010, today it is the solution most Node.js users turn to by default.
💫 Web scraping and automation
Cheerio is an HTML/XML parser widely used for web scraping work and sometimes in automating the tasks. It pretty quick and fast as it is based on jquery. Cheerio wraps around Parse5 parser and is capable enough to parse any type of HTML and XML documents.
Puppeteer is a headless browser widely used for automating browser tasks and can
only work with google chrome headless browser i.e chromium work with many browsers like Chromium/Chome, Firefox and Edge Chromium. Puppeteer can also be used for web scraping tasks. It is much powerful and feature-rich compared to the Cheerio HTML/XML parser.
🌷 Linters and formaters
Prettier is an opinionated code formatter. It enforces a consistent style by parsing your code and re-printing it with its own rules that take the maximum line length into account, wrapping code when necessary.
📦 Module bundlers and minimizers
Fast and efficient CSS optimizer for Node.js platform and any modern browser. Highly configurable and lots of compatibility modes.
👨💻 Process managers and runners
Simple monitor script for use during the development of a Node.js app. Useful for development, since it’s incredibly easy to restart and has file-watching enabled and baked in by default
Production process manager for Node.JS applications with a built-in load balancer. More comprehensive and better for production. Gives you lots of parameters to tune/act on.
Simple and straight to the point - useful tool for running multiple commands concurrently.
🚧 CLI and debuggers
EXECA is an alternative to
child_process and it offers improvements like promise interface, cross-platform shebang support, improved Windows support, higher max buffer and others.
Provides a fluent API for defining various aspects of CLI applications like the commands, options, aliases and help. Simplifies the creation of applications for the command line.
An easily embeddable and beautiful command-line interface for Node.js. Provides awesome inquiry session flow.
Chalk is an extremely simple library, created for one, simple purpose - styling your terminal strings.
Elegant terminal spinners.
🔩 System modules
Fs-extra contains methods that aren’t included in the vanilla Node.js fs package like
A module for some common directory and file operations, including for getting an array of files, subdirectories, and methods for reading and processing the contents of files.
A simple caching module that has set, get and delete methods and works a little bit like memcached. Keys can have a timeout (TTL) after which they expire and are deleted from the cache.
Helps you secure your apps by setting various HTTP headers. It’s Connect-style middleware, which is compatible with frameworks like Express.
DFKit is a PDF document generation library for Node and the browser that makes creating complex, multi-page, printable documents easy.
Comprehensive CSV suite combining 4 well-tested packages to generate, parse, transform and stringify CSV data.
Low-level compiler for parsing markdown without caching or blocking for long periods of time.
A tiny script for generating attractive random colors. You can pass an options object to influence the type of color it produces.
This module uses a pre-defined list of rules, applied in order, to singularize or pluralize a given word. There are many cases where this is useful, such as any automation based on user input.