Back to Errors

An import points at something that isn't there

What is this error?

A file asked to import something, and the bundler could not find it. Either the package is not installed, or the path is wrong.

Common Causes

  • The package is imported but never installed (missing from package.json).
  • The file path is wrong — a typo, wrong folder, or wrong casing.
  • Case sensitivity: it works on Windows/macOS and fails on the Linux build server.
  • node_modules is stale or partially installed.

How to fix it (Check First)

  • 1Read the exact name in the error and search your project for it.
  • 2If it is a package: is it listed in package.json dependencies?
  • 3If it is a file: does the file exist at that exact path, with that exact capitalisation?

What NOT to do

  • Do not install random similarly-named packages hoping one matches.
  • Do not delete the file that is erroring — it is the victim, not the cause.

Technical Details

Module resolution walks the import specifier against node_modules and the filesystem. Linux filesystems are case-sensitive; macOS default filesystems are not, which is why casing bugs only appear in CI.