Node.js

How to Debug a Node.js Application: Tips, Tricks and Tools

  • Satish 

What is Debugging? Debugging is the black art of fixing software defects. Fixing a bug is often easy — a corrected character or additional line of code solves the problem. Finding that bug is another matter, and developers can spend many unhappy hours trying to locate the source of an issue. Fortunately, Node.js has some great tools to help trace errors. Terminology Debugging has its own selection of obscure jargon, including the following: Term Explanation breakpoint the point at which a… Read More »How to Debug a Node.js Application: Tips, Tricks and Tools

Local Authentication Using Passport in Node.js

  • Satish 

In this tutorial, I’ll demonstrate how to use Passport to implement local authentication (that is, logging in with a username and password) with a MongoDB back end. Prerequisites To follow along with this tutorial, you’ll need to have Node and MongoDB installed on your machine. You can install Node by heading to the official Node download page and grabbing the correct binaries for your system. Alternatively, you can use a version manager — a program that allows you to install multiple versions of Node… Read More »Local Authentication Using Passport in Node.js

How to Use SSL/TLS with Node.js

  • Satish 

In this tutorial, I’ll walk you through a practical example of how to add a Let’s Encrypt–generated certificate to your Express.js server. But protecting our sites and apps with HTTPS isn’t enough. We should also demand encrypted connections from the servers we’re talking to. We’ll see that possibilities exist to activate the SSL/TLS layer even when it’s not enabled by default. Note: if you’re looking for instructions on how to set up SSL with NGINX when configuring it to work as… Read More »How to Use SSL/TLS with Node.js

Installing Multiple Versions of Node.js Using nvm

  • Satish 

When working with Node.js, you might encounter situations where you need to install multiple versions of the runtime. For example, maybe you have the latest version of Node set up on your machine, yet the project you’re about to start working on requires an older version. Or maybe you’re upgrading an old Node project to a more modern version and it would be handy to be able to switch between the two while you make the transition. Without a good… Read More »Installing Multiple Versions of Node.js Using nvm

How to Build Your First Discord Bot with Node.js

  • Satish 

Nowadays, bots are being used for automating various tasks. Since the release of Amazon’s Alexa devices, the hype surrounding automation bots has only started to grow. Besides Alexa, other communication tools like Discord and Telegram offer APIs to develop custom bots. This article will solely focus on creating your first bot with the exposed Discord API. Maybe the most well-known Discord bot is the Music Bot. The music bot lets you type a song name and the bot will attach… Read More »How to Build Your First Discord Bot with Node.js

The Node.js Event Loop: A Developer’s Guide to Concepts & Code

  • Satish 

Asynchrony in any programming language is hard. Concepts like concurrency, parallelism, and deadlocks make even the most seasoned engineers shiver. Code that executes asynchronously is unpredictable and difficult to trace when there are bugs. The problem is inescapable because modern computing has multiple cores. There’s a thermal limit in each single core of the CPU, and nothing is getting any faster. This puts pressure on the developer to write efficient code that takes advantage of the hardware. JavaScript is single-threaded,… Read More »The Node.js Event Loop: A Developer’s Guide to Concepts & Code

A Beginner Splurge in Node.js

  • Satish 

One exciting thing about Node.js is that it runs anywhere. This opens up various possibilities for experimenting with the stack. For any seasoned veteran, this is a fun run of the command line tooling. What’s extra special is that we can survey the stack from within the safety net of the command line. And it’s cool that we’re still talking about JavaScript — so most readers who are familiar with JS shouldn’t have any problem understanding how it all works.… Read More »A Beginner Splurge in Node.js

What Is Node and When Should I Use It?

  • Satish 

So you’ve heard of Node.js, but aren’t quite sure what it is or where it fits into your development workflow. Or maybe you’ve heard people singing Node’s praises and now you’re wondering if it’s something you need to learn. Perhaps you’re familiar with another back-end technology and want to find out what’s different about Node. If that sounds like you, then keep reading. In this article, I’ll take a beginner-friendly, high-level look at Node.js and its main paradigms. I’ll examine… Read More »What Is Node and When Should I Use It?