Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Next failed to load SWC binary

When trying to run the command using nextjs npm run dev shows error - failed to load SWC binary see more info here: https://nextjs.org/docs/messages/failed-loading-swc.

I've tried uninstalling node and reinstalling it again with version 16.13 but without success, on the vercel page, but unsuccessful so far. Any tips?

Also, I noticed it's a current issue on NextJS discussion page and it has to do with the new Rust-base compiler which is faster than Babel.

like image 556
Ekama Emmanuel Uloho Avatar asked Dec 03 '22 17:12

Ekama Emmanuel Uloho


1 Answers

Delete the package-lock.json file and the node_modules directory in your project and then run npm install on your terminal.

like image 145
Joon Kyoung Avatar answered Jun 09 '23 18:06

Joon Kyoung