Skip to content

Instantly share code, notes, and snippets.

@Raynos
Forked from neonstalwart/index.js
Last active August 29, 2015 14:02
Show Gist options
  • Save Raynos/76eda122df6ec5c38435 to your computer and use it in GitHub Desktop.
Save Raynos/76eda122df6ec5c38435 to your computer and use it in GitHub Desktop.
var mercury = require("mercury")
var h = mercury.h
var state = mercury.hash({})
function render(state) {
return h("ul", [
h('li', h('a', { href: '#foo' }, 'link without array')),
h('li', [ h('a', { href: '#bar' }, 'link with array') ])
])
}
mercury.app(document.body, state, render)
{
"name": "requirebin-sketch",
"version": "1.0.0",
"dependencies": {
"mercury": "3.2.4"
}
}
<style type='text/css'>html, body { margin: 0; padding: 0; border: 0; }
body, html { height: 100%; width: 100%; }</style>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment