DocSpring / craco-antd

A craco plugin to use Ant Design with create-react-app
MIT License
234 stars 49 forks source link

Not able to install craco-antd, with CRA 4 (npm 8 and node 16.x) and using "@craco/craco": "^6.4.5", #104

Open bhupendrayadav opened 1 year ago

bhupendrayadav commented 1 year ago

image

"@craco/craco": "^6.4.5" asking to change "@craco/craco": "^6.4.3", does not make sense , right ?

Dijky commented 1 year ago

The problem is that craco-antd has "react-scripts": "5.0.1" and "@craco/craco": "6.4.3" in peerDependencies, but Craco 6 does not officially support CRA/react-scripts 5 (supported in Craco 7-alpha).

You can install it anyway with npm install --force, but nonetheless this situation is problematic.
E.g. I can't run npm audit fix without --force because auf the peer dependency conflict.

IMO, craco-antd should either remove or adjust the react-scripts version in peerDependencies to 4.

kigary commented 8 months ago

no response almost a year. yarn is totally okay with that, but we do not want to migrate from npm to yarn. As a workaround we set legacy-peer-deps to true on local machines and in github workflow, but it can lead to other issues if we do not constantly audit packages manually