Created
June 12, 2017 16:51
-
-
Save fresh5447/1a0af20c29cdb79b2039b282ae4f4f1c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React from 'react' | |
| import ReactDOM from 'react-dom' | |
| import getMuiTheme from 'material-ui/styles/getMuiTheme' | |
| import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider' | |
| import { BrowserRouter as Router, Route } from 'react-router-dom' | |
| import './index.css' | |
| import injectTapEventPlugin from 'react-tap-event-plugin' | |
| import { importantPlugin } from './lib/jss-extras' | |
| import preset from 'jss-preset-default' | |
| import { jss } from 'react-jss' | |
| import registerServiceWorker from './registerServiceWorker' | |
| import ContactPage from './Views/Contact' | |
| import ContactForm from './Views/ContactForm' | |
| import {one, two, three} from './Views' | |
| import Home from './Views/Home' | |
| const theme = getMuiTheme({ | |
| palette: { | |
| primary1Color: '#ffffff', | |
| primary2Color: '#0097A7', | |
| primary3Color: '#BDBDBD', | |
| accent1Color: '#550000', | |
| accent2Color: '#F5F5F5', | |
| accent3Color: '#9E9E9E', | |
| textColor: '#550000', | |
| alternateTextColor: '#550000', | |
| canvasColor: '#ffffff', | |
| borderColor: '#E0E0E0', | |
| pickerHeaderColor: '#00BCD4' | |
| } | |
| }) | |
| injectTapEventPlugin() | |
| const jssPlugins = preset() | |
| jssPlugins.plugins.push(importantPlugin) | |
| jss.setup(jssPlugins) | |
| ReactDOM.render(( | |
| <MuiThemeProvider muiTheme={theme} > | |
| <div> | |
| <Router> | |
| <Route> | |
| <div> | |
| <div> | |
| <h1>Hello form main </h1> | |
| </div> | |
| <div> | |
| <Route exact path='/' component={Home} /> | |
| <Route path='/contact' component={ContactPage} /> | |
| <Route path='/contact/form' component={ContactForm} /> | |
| </div> | |
| </div> | |
| </Route> | |
| </Router> | |
| </div> | |
| </MuiThemeProvider> | |
| ), | |
| document.getElementById('root') | |
| ) | |
| registerServiceWorker() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment