sst.dev
sst.dev copied to clipboard
Uncaught TypeError: (0 , _reactRouterDom.useNavigate) is not a function at LinkContainer
Doing the tutorial, I had trouble adding links to the navbar. The command
npm install react-router-bootstrap
currently installs v0.26.0
, which added support for React Router v6. This is not compatible with the specified version of "react-router-dom": "^5.2.0"
in the tutorial, which uses the old useHistory
function instead of useNavigate
.
I was able to fix the issue by running
npm install [email protected] --save
in the frontend
folder, to match the version in the tutorial repository.
Maybe we should mention this in the tutorial ?