It looks like i have some problem with react-router-dom package if i try to install it i have this warning (see the screenshot):
npm WARN react-router-dom@4.0.0 requires a peer of react@^15 but none is installed.
You must install peer dependencies yourself.
npm WARN react-router@4.2.0 requires a peer of react@>=15 but none is installed.
You must install peer dependencies yourself.
I also tried to update all the packages but with bad results.
Any suggestion?
Follow the below steps.
hope so this will resolve your issue.
You have react-router-dom of v 4.0.0, and a react of v 0.14.3. It's time to upgrade your react. The error has made it clear that react-router-dom requires react of > 15 but you are at 0.14.3.
Step 1:
delete the react, react-dom, react-redux, and redux from node_modules
Step2:
update your package.json with latest versions of these packages: react, react-dom, react-redux, redux. As of now, their versions are:
"react": "^16.4.1",
"react-dom": "^16.4.1",
"react-redux": "^5.0.7",
"react-router-dom": "^4.3.1",
"redux": "^4.0.0",
step3:
npm install
This should fix the problem permanently.
Have you installed react? Can you first try to execute below command and then install react-router-dom: npm install react --save