mirror of
https://github.com/hazemKrimi/react-weather-app.git
synced 2026-05-02 02:30:30 +00:00
Update routes
This commit is contained in:
@@ -20,6 +20,9 @@ const App: React.FC = () => {
|
||||
<Route path='/' exact>
|
||||
<Home />
|
||||
</Route>
|
||||
<Route path='/home' exact>
|
||||
<Home />
|
||||
</Route>
|
||||
<Route path='/search/:query'>
|
||||
<Search />
|
||||
</Route>
|
||||
|
||||
@@ -20,7 +20,7 @@ const NavBar: React.FC = () => {
|
||||
|
||||
return (
|
||||
<Nav>
|
||||
<h1 onClick={() => history.push('/')}>Weather</h1>
|
||||
<h1 onClick={() => history.push('/home')}>Weather</h1>
|
||||
<SearchBar />
|
||||
</Nav>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user