I have been building a Next js app with dark mode functionality from shadcn. I followed all steps from shadcn and install all modules but when I run the app, it gives me this error.
I think its because of the lucide-react-icons. I tried fixing but its not.
Any Solutions?
I tried installing lucid react but its not working.
2
Answers
I had same error. The workaround is to downgrade lucide-react to 0.263.1
This is an issue from the new Nextjs upgrade, but there are easy workaround, you can just import from your node modules like:
import { Sun, Moon } from '../../node_modules/lucide-react';
Or downgrade your Lucide react to
"lucide-react": "0.263.1",
justnpm install [email protected]