BUILD — a counter with persistence
Combine all 5 opcodes to make a working counter. Save it to the cloud. Take it offline. Come back. The state is yours.
01The shape
Combine all 5 opcodes to make a working counter. Save it to the cloud. Take it offline. Come back. The state is yours.
02Try it
03What you've built
A working counter. It uses all 5 opcodes:
• BIND to create the count cell
• EFFECT for increment, decrement, reset
• VIEW to read the current value
• TICK to advance time on each change
• LINK would be used to chain counters together (try it!)
It saves to localStorage, so it survives a page reload. Click Save to cloud below to put it in Cloudflare KV and get a share URL.
04What you can build
A counter. It seems small, but it's the seed of every reactive UI, every versioned config, every CRDT, every game state. The substrate doesn't know about counters. It knows about 5 opcodes. You composed them into a counter. The composition is yours.
05Next
You finished the Academy. Try the full REPL → · See the 5 apps → · Visual playground →