Skip to content

Instantly share code, notes, and snippets.

@yelouafi
Created July 28, 2015 12:23
Show Gist options
  • Save yelouafi/e679d2d474a7bb1780df to your computer and use it in GitHub Desktop.
Save yelouafi/e679d2d474a7bb1780df to your computer and use it in GitHub Desktop.
function view(count, handler) {
return h('div', [
h('button', {
on : { click: handler.bind(null, Action.Increment()) }
}, '+'),
h('button', {
on : { click: handler.bind(null, Action.Decrement()) }
}, '-'),
h('div', `Count : ${count}`),
]);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment