I can't understand what the problem is
App.js
import React from 'react'
import {Router, Route} from 'react-router-dom';
import Header from './components/Header';
import Home from './views/Home.js'
import Register from './views/Register.js'
const App = () => {
return (
<Router>
<Header/>
<Route path="/register" component={Register} />
<Route path="/" component={Home} exact />
</Router>
);
}
export default App;
TypeError: Cannot read property 'pathname' of undefined
278 | }
279 |
280 | let {
> 281 | pathname = "/",
| ^ 282 | search = "",
283 | hash = "",
284 | state = null,