Frontend error after chaged to index.js

I get the following error after npm start, following the changes to load the index page.

Failed to compile.

Attempted import error: ‘Switch’ is not exported from ‘react-router-dom’.

The latest version of react native does not support node v12. However, the manual was written when it did support v12.
Switch has been changed from react router v6 to Routes.
need to down react router to v5 or apply the changes.

thank you, I checked what local packages installed in React app.
├── @liskhq/lisk-client@5.2.1
├── react@17.0.2
├── react-dom@17.0.2
├── react-router-dom@6.2.1
└── react-scripts@3.1.1

react-router-dom@6.2.1 is the target.
Down the version may cause other dependency issues, so it is recommended to follow the official upgrading procedure.