add restentpoint for login/logout, restructuring of modules and components, add flow usage

This commit is contained in:
Maren Süwer
2018-07-04 16:43:46 +02:00
parent 85902010ce
commit 3cc87ede73
22 changed files with 646 additions and 99 deletions

View File

@@ -0,0 +1,35 @@
import React, { Component } from "react";
import Navigation from "./Navigation";
import Main from "./Main";
import Login from "./Login";
import { withRouter } from "react-router-dom";
type Props = {
login: boolean
}
class App extends Component {
render() {
const { login} = this.props;
if(login) {
return (
<div>
<Login/>
</div>
);
}
else {
return (
<div className="App">
<Navigation />
<Main />
</div>
);
}
}
}
export default withRouter(App);