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.

App throws error on Building with npm run build

See original GitHub issue

Describe the bug After I build my app which is using react-carousel for production using npm run build, it gives an error when I try to open the page where react-carousel is used. The error screenshots are provided below

Expected behavior To render the page as it appears during development.

Screenshots image

Environment

  • node 14.4.0, npm 6.14.5, react-carousel 2.0.1
  • Desktop Windows 10
  • Edge, Chrome

Please look into this. Its a great library and the best one for my purpose but this error blindsided me.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:14
  • Comments:20 (9 by maintainers)

github_iconTop GitHub Comments

4reactions
marpstarcommented, Jan 4, 2021

@mnelemans what’s the right way to install the latest commit from your PR?

I can’t find a way to do that.

I got this working by

  1. Clone @mnelemans 's fork
  2. yarn
  3. yarn build
  4. Copy the contents of react-carousel/lib into my project’s node_modules/@brainhubeu/react-carousel/lib folder and overwriting the existing files.

After rebuilding my create-react-app project, everything seems to work.

1reaction
rstefekcommented, Apr 7, 2021

Please merge that PR, this is quite annoying bug

Read more comments on GitHub >

github_iconTop Results From Across the Web

npm run build - fails to compile despite development version ...
I have a react app created with create-react-app , and npm run build is failing to compile a production build. It throws the...
Read more >
`npm run build` is failing on CI but runs fine on local machine
Hey I got really weird problem. I use CRA with TypeScript template. I cannot build my app using npm run build on Github...
Read more >
Troubleshooting Node.js Deploys - Heroku Dev Center
Start with these simple steps to troubleshoot a build issue. ... heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" ...
Read more >
"npm build / npm run build" shows error : r/reactjs - Reddit
"npm build / npm run build" shows error · Tried running `npm run-script build` · Tried doing `npm cache clean --force` · Tried...
Read more >
npm run build command fails - Salesforce Stack Exchange
Windows still has some tweaks necessary, if you look in package.json in the scripts field you'll see the run command, which probably looks ......
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