

In this article, we will cover the following topics for initial setup of Node.js: Node.js provides a package manager for installing and managing all these external modules, which is called "Node Package Manager( NPM)". We have to install these modules separately. Node.js also can embed external functionality/library by using custom modules. The Node.js framework is available for a variety of operating systems such as Windows, Ubuntu, and OS X. You are required to Install Node JS framework before start building your Node.js application. Additionally, it includes everything you need to run a program written in JavaScript. It is open-source, totally free of cost, and millions of developers use it across the globe. Moreover, it is built on Chrome's V8 JavaScript engine. Next you'll need to open your is a server-side runtime environment. Navigate to a suitable place on your machine and create a new folder named discord-bot (or whatever you want). However, before you install anything, you should set up a new project folder. npm comes with every Node installation, so you don't have to worry about installing that.

To use discord.js, you'll need to install it via npm (Node's package manager). On Linux, you can consult this page open in new window to determine how you should install Node. Use a package manager like Homebrew open in new window with the command brew install node.Download the latest version from the Node.js website open in new window, open the package installer, and follow the instructions.

Download the latest version from the Node.js website open in new window, open the downloaded file, and follow the steps from the installer. On Windows, it's as simple as installing any other program. If it outputs v16.9.0 or higher, then you're good to go! Otherwise, continue reading. To check if you already have Node installed on your machine (e.g., if you're using a VPS), run node -v in your terminal.
