Created
March 29, 2017 11:07
-
-
Save timwis/fb5de5ba1a2702887dfb9b143976f6c5 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
const html = require('choo/html') | |
const component = require('nanocomponent') | |
const menu = require('../components/menu') | |
module.exports = function home (state, emit) { | |
return component({ | |
render: (state, emit) => { | |
return html` | |
<body> | |
<h1>Hello, world</h1> | |
<div class="columns"> | |
<div class="column is-one-quarter"> | |
${menu(state.sheets, state.activeSheet)} | |
</div> | |
<div class="column"> | |
Rows | |
</div> | |
</div> | |
</body> | |
` | |
}, | |
onload: (el) => { | |
console.log('onload') | |
emit('sheets:getList') | |
} | |
})(state, emit) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment