-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathapp.js
30 lines (28 loc) · 841 Bytes
/
app.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import React from 'react';
import {Switch, Link, Route, Redirect} from 'react-router-dom';
import Home from './home';
import Contact from './contact';
import {withFlagProvider} from 'ld-react';
const App = () =>
<div>
<header>
<nav>
<ul>
<li><Link to="/">Home</Link></li>
<li><Link to="/contact">Contact</Link></li>
</ul>
</nav>
</header>
<main>
<Switch>
<Route exact path="/" component={Home}/>
<Route path="/home">
<Redirect to="/"/>
</Route>
<Route path="/contact" component={Contact}/>
</Switch>
</main>
</div>;
// Set clientSideId to your own Client-side ID. You can find this in
// the dashboard under Account settings / Projects
export default withFlagProvider(App, {clientSideId: '59b2b2596d1a250b1c78baa3'});