Categories
JavaScript Answers

How to install a Node.js module without using npm?

Spread the love

To install a Node.js module without using npm, we download the module into the node_modules directory.

After we downloaded the module into the folder, we write

const moduleName = require("foo");

in our code to import the foo module assuming that’s what we downloaded.

By John Au-Yeung

Web developer specializing in React, Vue, and front end development.

Leave a Reply

Your email address will not be published. Required fields are marked *