question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error while building

See original GitHub issue

When I used react-static create to create the sample application and selected basic template, I get this error when I ran yarn build

ERROR in ./src/App.js
Module not found: Error: Can't resolve 'react-static-routes' in '/Users/Zama/Desktop/passion/my-static-site/src'
 @ ./src/App.js 13:25-55
 @ ./src/index.js
 @ multi ./src/index

=> There were ERRORS during the production build stage! :(
=> Fix them and try again!

and when I selected custom routing, I got this error

TypeError: (0 , _reactStatic.getSiteProps) is not a function
    at Object.<anonymous> (/Users/Zama/Desktop/passion/custom-static-site/src/containers/Home.js:4:16)
    at Module._compile (module.js:570:32)
    at loader (/Users/Zama/Desktop/passion/custom-static-site/node_modules/babel-register/lib/node.js:144:5)
    at Object.require.extensions.(anonymous function) [as .js] (/Users/Zama/Desktop/passion/custom-static-site/node_modules/babel-register/lib/node.js:154:7)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/Zama/Desktop/passion/custom-static-site/src/App.js:4:1)

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:3
  • Comments:12 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
neilyoungcommented, Nov 26, 2020

No. Nothing of that. After hours of deinstall/install on ubuntu it works now. Don’t ask me why…

0reactions
neilyoungcommented, Nov 26, 2020

Thanks 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why do I have error while building project? - Stack Overflow
How can I fix this error? Start by removing the private keyword from those properties on Result . That should reduce the errors...
Read more >
Fix a build error
To fix a build error, select the error in the Error List and double-click it. If the error relates to: a multiply proven...
Read more >
Project build errors and warnings (PRJxxxx) - Microsoft Learn
The Visual Studio compilers and build tools can report many kinds of errors and warnings. After an error or warning is found, the...
Read more >
error while building solution - Visual Studio Feedback
Hi Team,. I am trying to build a MVC application through TFS and getting errors. However, when I build the solution locally it...
Read more >
Error while Building Android - Google Groups
Hello.. I checked android source code and start building it using make command but I got the following error . doc tag do...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found