Error: Cannot find module


(Kat Marchán) #1

If when running npm (not your application), you get an error about a module not being found, this almost certainly means that there’s something wrong with your npm installation.

If this happens when trying to start your application, you might not have installed your package’s dependencies yet.

Examples

module.js:338
    throw err;
          ^
Error: Cannot find module

Related Issues


(Kat Marchán) #2

Steps to Fix

  1. If this happens when you try to start your application, try running npm install to install the app’s dependencies. Make sure all its actual dependencies are listed in package.json

  2. If this happens on any npm command, please reinstall.