[Solved] Error when using react router

Unable to resolve some modules:

“”./App.js" in /Users/arvind/Sites/projectname/imports/ui/Routes.js (web.browser)
“”./About.js" in /Users/arvind/Sites/projectname/imports/ui/Routes.js (web.browser)

If you notice problems related to these missing modules, consider running:

meteor npm install --save ".

W20180701-13:50:22.846(-6)? (STDERR) /Users/arvind/.meteor/packages/meteor-tool/.1.7.0_3.13zrrz.fr2jb++os.osx.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:280
W20180701-13:50:22.846(-6)? (STDERR) throw(ex);
W20180701-13:50:22.847(-6)? (STDERR) ^
W20180701-13:50:22.847(-6)? (STDERR)
W20180701-13:50:22.847(-6)? (STDERR) Error: Cannot find module ‘"./App.js’
W20180701-13:50:22.847(-6)? (STDERR) at Function.Module._resolveFilename (module.js:547:15)
W20180701-13:50:22.847(-6)? (STDERR) at Function.resolve (internal/module.js:18:19)
W20180701-13:50:22.847(-6)? (STDERR) at Object.require (/Users/arvind/Sites/projectname/.meteor/local/build/programs/server/boot.js:288:32)
W20180701-13:50:22.848(-6)? (STDERR) at makeInstallerOptions.fallback (packages/modules-runtime.js:604:18)
W20180701-13:50:22.848(-6)? (STDERR) at Module.require (packages/modules-runtime.js:230:14)
W20180701-13:50:22.848(-6)? (STDERR) at require (packages/modules-runtime.js:244:21)
W20180701-13:50:22.848(-6)? (STDERR) at Routes.js (imports/ui/Routes.js:1:247)
W20180701-13:50:22.848(-6)? (STDERR) at fileEvaluate (packages/modules-runtime.js:322:7)
W20180701-13:50:22.849(-6)? (STDERR) at Module.require (packages/modules-runtime.js:224:14)
W20180701-13:50:22.849(-6)? (STDERR) at require (packages/modules-runtime.js:244:21)
W20180701-13:50:22.849(-6)? (STDERR) at main.js (server/main.js:1:358)
W20180701-13:50:22.849(-6)? (STDERR) at fileEvaluate (packages/modules-runtime.js:322:7)
W20180701-13:50:22.849(-6)? (STDERR) at Module.require (packages/modules-runtime.js:224:14)
W20180701-13:50:22.849(-6)? (STDERR) at require (packages/modules-runtime.js:244:21)
W20180701-13:50:22.849(-6)? (STDERR) at /Users/arvind/Sites/projectname/.meteor/local/build/programs/server/app/app.js:121:15
W20180701-13:50:22.850(-6)? (STDERR) at /Users/arvind/Sites/projectname/.meteor/local/build/programs/server/boot.js:411:36
W20180701-13:50:22.850(-6)? (STDERR) at Array.forEach ()
W20180701-13:50:22.850(-6)? (STDERR) at /Users/arvind/Sites/projectname/.meteor/local/build/programs/server/boot.js:220:19
W20180701-13:50:22.850(-6)? (STDERR) at /Users/arvind/Sites/projectname/.meteor/local/build/programs/server/boot.js:471:5
W20180701-13:50:22.850(-6)? (STDERR) at Function.run (/Users/arvind/Sites/projectname/.meteor/local/build/programs/server/profile.js:510:12)
W20180701-13:50:22.850(-6)? (STDERR) at /Users/arvind/Sites/projectname/.meteor/local/build/programs/server/boot.js:470:11

This looks like an issue with import statements. Please check that you are importing things properly (ie. correct path, proper exports and import of variables, etc.).

I’ve figured it out @storyteller, its true, there were a couple of imports that I need to fix.

1 Like