forked from cerebral/overmind
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.tsx
More file actions
37 lines (31 loc) · 787 Bytes
/
index.tsx
File metadata and controls
37 lines (31 loc) · 787 Bytes
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
31
32
33
34
35
36
37
import { injectGlobal } from 'emotion'
import { render } from 'react-dom'
import { createElement } from 'react'
import Devtools from './components/Devtools'
import { overmind } from './overmind'
import { css } from './theme'
injectGlobal`
${css}
html, body {
margin: 0 !important;
padding: 0 !important;
height: 100%;
}
body {
overflow: hidden;
font-family: Nunito, 'helvetica neue';
background-color: var(--colors-background);
color: var(--colors-text);
line-height: 24px;
}
#app {
height: 100%;
}
`
window.onerror = (_, _2, _3, _4, error) => {
overmind.actions.setError(error.message)
}
const container = document.createElement('div')
container.id = 'app'
document.body.appendChild(container)
render(<Devtools />, container)