Open ctafsiras opened 5 days ago
Facing the same issue. This happened because Next Js upgrading to react 19 rc version since it is not full released version Shadcn does not support auto installation. Having this problem users will be unable to install shadcn on on projects that are using react 19 rc edition or next js latest version. Hope shadcn patches this issue fast.
this is a temporary fix:
"overrides": {
"@radix-ui/react-icons": {
"react": "$react"
}
}
One fix is to downgrade to React 18 within your project.
package.json
, set "react"
and "react-dom"
versions to "^18"
.node_modules
.npm install
in the terminal.One fix is to downgrade to React 18 within your project.
- In
package.json
, set"react"
and"react-dom"
versions to"^18"
.- Delete
node_modules
.- Run
npm install
in the terminal.
I have faced the same issue and this method solved my problem. Thank you.
npm install tailwindcss-animate class-variance-authority clsx tailwind-merge check the post https://tutorialsmaterial.com/post/ShadCn-Nextjs-15
@shadcn it's a big one
does the following help? https://ui.shadcn.com/docs/react-19#using-shadcnui-on-nextjs-15
Describe the bug
Something went wrong. Please check the error below for more details. If the problem persists, please open an issue on GitHub.
Command failed with exit code 1: npm install tailwindcss-animate class-variance-authority lucide-react @radix-ui/react-icons clsx tailwind-merge npm error code ERESOLVE npm error ERESOLVE unable to resolve dependency tree npm error npm error While resolving: cybership-io@0.1.0 npm error Found: react@19.0.0-rc-69d4b800-20241021 npm error node_modules/react npm error react@"19.0.0-rc-69d4b800-20241021" from the root project npm error npm error Could not resolve dependency: npm error peer react@"^16.x || ^17.x || ^18.x" from @radix-ui/react-icons@1.3.0 npm error node_modules/@radix-ui/react-icons npm error @radix-ui/react-icons@"*" from the root project npm error npm error Fix the upstream dependency conflict, or retry npm error this command with --force or --legacy-peer-deps npm error to accept an incorrect (and potentially broken) dependency resolution. npm error npm error npm error For a full report see: npm error C:\Users\Tafsir\AppData\Local\npm-cache_logs\2024-10-27T12_41_49_804Z-eresolve-report.txt npm error A complete log of this run can be found in: C:\Users\Tafsir\AppData\Local\npm-cache_logs\2024-10-27T12_41_49_804Z-debug-0.log
Affected component/components
Not installing
How to reproduce
Codesandbox/StackBlitz link
No response
Logs
System Info
Before submitting