Mithril.js 0-60

    var App = {
        view: function(){
            return m('h1', 'Hello, World!')
        }
    }
    
    m.mount(document.body, App)
    var count = 0
    
    var App = {
        view: function(){
            return m(''
                , m('p', count)
                , m('button', {onclick: function(){count++}}, 'click me')
            )
        }
    }
    
    m.mount(document.body, App)
    var ButtonComponent = {
        view: function(vnode){
            return m('button'
                , {
                    onclick: function(){
                        vnode.attrs.current.title = vnode.attrs.text
                    }
                }
                , vnode.attrs.text
            )
        }
    }
    
    var Display = {
    var ButtonComponent = require('./ButtonComponent').component
    var Display = require('./Display').component
    
    var App = {
        view: function(vnode){
            return m(''
                , m(ButtonComponent, {text: "Left"})
                , m(ButtonComponent, {text: "Right"})
                , m(Display)
            )
        }
    }
    
    m.mount(document.body, App)
    var State = require('./Globals').state
    var ButtonComponent = require('./ButtonComponent').component
    var Display = require('./Display').component
    
    var App = {
        view: function(vnode){
            return m(''
                , State.things().map(function(thing){
                    return m(ButtonComponent, { text: thing.name })
                })
                , State.current !== null
                    ? m(Display)
                    : m('h3', 'nothing clicked yet.')
            )