git ssb

2+

ev / mvd



Tree: 60992568ce06b2ff2d69fca74183e88c6bdf1e1b

Files: 60992568ce06b2ff2d69fca74183e88c6bdf1e1b / index.js

618 bytesRaw
1var h = require('hyperscript')
2var route = require('./views')
3
4document.head.appendChild(h('style', require('./style.css.json')))
5
6var content = h('div.content')
7
8var screen = h('div#screen', {style: {position: 'absolute', top: '0px', bottom: '0px', left: '0px', right: '0px'}})
9
10document.body.appendChild(screen)
11route()
12
13window.onhashchange = function () {
14 var screen = document.getElementById('screen')
15
16 var newscreen = h('div#screen', {style: {position: 'absolute', top: '0px', bottom: '0px', left: '0px', right: '0px'}})
17
18 console.log(screen)
19 screen.parentNode.replaceChild(newscreen, screen)
20 route()
21}
22
23

Built with git-ssb-web