PageRenderTime 170ms CodeModel.GetById 1ms app.highlight 1ms RepoModel.GetById 167ms app.codeStats 1ms

/app/components/Counter.io

http://github.com/pgregory/blackpool
Unknown | 11 lines | 10 code | 1 blank | 0 comment | 0 complexity | 70653d18ecd982e5254a5c3cf0a83313 MD5 | raw file
 1Counter := Object clone do(
 2  init := method(
 3    count ::= 0
 4  )
 5
 6  renderOn := method(html,
 7    html h1 with( html text("Counter: " .. count))
 8    html link("--", block(count = count - 1))
 9    html link("++", block(count = count + 1))
10  )
11)