diff options
Diffstat (limited to 'frontend/src/App.js')
| -rw-r--r-- | frontend/src/App.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/frontend/src/App.js b/frontend/src/App.js index af2f99d..19e3426 100644 --- a/frontend/src/App.js +++ b/frontend/src/App.js @@ -1,7 +1,8 @@ -import React, { useEffect } from 'react'; +import React, { useEffect, useState } from 'react'; import { Router } from '@reach/router'; import Login from './Login'; +import Register from './Register'; import Home from './Home'; import userState from './UserState'; import './App.css'; @@ -15,6 +16,7 @@ const App = () => { const { username } = resp.data; userState.username = username; } catch (err) { + userState.authError = err; console.error(err); } }; @@ -25,7 +27,8 @@ const App = () => { <div className="App"> <Router> <Login path="/login" /> - <Home path="/" /> + <Register path="/register" /> + <Home path="/" exact /> </Router> </div> ); |
