2019-08-03 13:36:29 +09:00
|
|
|
import React, { Suspense } from 'react'
|
|
|
|
import styled from 'styled-components'
|
2019-07-30 23:27:28 +09:00
|
|
|
import ReactDOM from 'react-dom'
|
2019-07-31 14:17:32 +09:00
|
|
|
import ReactGA from 'react-ga'
|
2019-08-03 13:36:29 +09:00
|
|
|
import BarLoader from 'react-spinners/BarLoader'
|
2019-07-30 23:27:28 +09:00
|
|
|
import App from './App'
|
2019-08-02 04:23:21 +09:00
|
|
|
import * as serviceWorker from './serviceWorker'
|
2019-07-27 19:18:54 +09:00
|
|
|
|
2019-08-03 13:36:29 +09:00
|
|
|
import './i18n'
|
|
|
|
|
|
|
|
const Fallback = () => (
|
|
|
|
<Container>
|
|
|
|
<BarLoader />
|
|
|
|
</Container>
|
|
|
|
)
|
|
|
|
|
|
|
|
const Container = styled.div`
|
|
|
|
width: 100vw;
|
|
|
|
height: 100vh;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
justify-content: center;
|
|
|
|
align-items: center;
|
|
|
|
`
|
|
|
|
|
|
|
|
ReactDOM.render(
|
|
|
|
<Suspense fallback={<Fallback />}>
|
|
|
|
<App />
|
|
|
|
</Suspense>,
|
|
|
|
document.getElementById('root')
|
|
|
|
)
|
2019-08-01 01:10:09 +09:00
|
|
|
|
2019-07-31 14:17:32 +09:00
|
|
|
ReactGA.initialize('UA-28919359-15')
|
|
|
|
ReactGA.pageview(window.location.pathname + window.location.search)
|
|
|
|
|
2019-08-03 00:35:54 +09:00
|
|
|
serviceWorker.register()
|