0

Hello im making my first npm package called easier-discordjs but when i do npm link in my main module folder and in my test module folder it gives an error.

npm link easier-discordjs
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/easier-discordjs - Not found
npm ERR! 404  'easier-discordjs@*' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\niels\AppData\Local\npm-cache\_logs\2021-06-22T15_59_17_982Z-debug.log

My index.js for my main module is this:

module.exports = (name) => {
    return `Hello ${name}!`;
};

My index.js for my test module is this:

const greeter = require('easier-discordjs');

console.log(greeter('Niels'))

I don't know what to do.

1 Answers1

0

As said in the NPM docs, you must first execute the command npm link in easier-discordjs project folder and then execute npm link easier-discordjs in your test project.

MrNossiom

Milo Moisson
  • 119
  • 1
  • 10