📅  最后修改于: 2022-03-11 15:01:51.605000             🧑  作者: Mango
Here Just Install Switch.
...And then you can use Switch.
...Switch is replaced in react-router-dom version 6.
...So that you need to install react-router-dom version 5.
...Now, your error should be solved.
Run the command below in your terminal
npm install react-router-dom@5