You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.0 KiB
39 lines
1.0 KiB
import React, { Component } from "react"; |
|
import { Route, Switch } from "react-router-dom"; |
|
|
|
import Login from "./Auth/Login"; |
|
import Register from "./Auth/Register"; |
|
import About from "./Static/About"; |
|
import Footer from "./Static/Footer"; |
|
import Home from "./Static/Home"; |
|
import NoMatch from "./Static/NoMatch"; |
|
import Navbar from "./Navbar"; |
|
|
|
class App extends Component { |
|
render() { |
|
const footSmash = { |
|
display: "flex", |
|
minHeight: "calc(100vh - 1px)", |
|
flexDirection: "column" |
|
}; |
|
return ( |
|
<div> |
|
<Navbar /> |
|
<div style={footSmash}> |
|
<div style={{ flex: "1" }}> |
|
<Switch> |
|
<Route exact path="/" component={Home} /> |
|
<Route path="/about" component={About} /> |
|
<Route path="/auth/login" component={Login} /> |
|
<Route path="/auth/register" component={Register} /> |
|
<Route component={NoMatch} /> |
|
</Switch> |
|
</div> |
|
<Footer /> |
|
</div> |
|
</div> |
|
); |
|
} |
|
} |
|
|
|
export default App;
|
|
|