Helpful Node.js Modules to Know
Have you ever sat down to pick out a film or show to stream and drawn a complete blank? You’re kicked back and ready to binge your ass off but somehow everything and nothing sound good simultaneously. This feeling is a byproduct of being spoiled for choice. Consumer demand has pushed the need for new content exponentially with no end in sight. Without some bright blinking signs it can be difficult to navigate the growing landscape of media. In software development, Node.js continues to explode in popularity among some of the most successful companies in the world. This is due to Node’s massive library of modules. Developers contribute daily to the Node Packet Manager universe resulting in a huge variety of options when it comes to features and tools. Much like trying to decide on one movie out of a million it can be tough to know where to start with such an embarrassment of riches. Here is a list of Node modules proven to make life easier.
Cloudinary — Free-to-use and perfect for any of your web application’s imaging needs. It is a cloud service allowing you to upload visual content and manipulate images. Ease of use is perfect for newcomers.
Spritesmith — Sprite sheets can be used to reduce the overhead of downloading images and improve speed. Generating sprite sheets manually can be a pain. This takes a folder and combines all the images into one sprite sheet. The coordinates of the images are saved to JSON file which can be used directly into CSS.
Sharp — High speed module used to resize images. As well as image resizing, operations such as rotation, extraction, compositing and gamma correction are available.
TinyColor2 — Allows for easy color manipulation. Useful for conversion methods and color operations.
Passport — Adds custom authorization features. API requests are sent to Passport and it in turn sends back hooks that can be customized for success or failure.
Validator.js — One stop for all validation needs. Checks for correct user inputs with customizable alerts.
Nodemailer — A secure framework for handling emails in Node.js projects. Easy to understand and safe to use.
JSHint — Great for debugging code. Scans a project written in JS and reports on common mistakes and bugs. Dramatically cuts down on time looking for mistakes.
Morgan — HTTP request logger. Analyzes requests and shows exactly how the app is being used and where there might be potential problems.
Date and Time
Moment.js — Easy to use API for displaying, printing, and calculating time. Much more user-friendly than the built-in Date module.
WebPack — Packs all modules in separate JS, CSS, and HTML files, allowing for code to be split and allocated in any way needed without need to worry about their location.
Less —Free CSS pre-processor that can greatly improves frontend work flow. Allows CSS to act more like a language rather than just a scripting environment.
NodeMySQL — Takes the tried-and-true power of MySQL and makes it available to Node. Nothing special here just pure experience.
Get Into the Sandbox
Hopefully these suggestions are helpful on the road to finding the perfect feature for your next app. You can always feel comfortable knowing that thousands of developers have almost certainly spent the time and effort tackling your problem and simplifying a solution already. Contribute to the NPM community and help future developers tackle problems you’ve overcome.