Start with Messages. This defines the state of the front-end
(the World), and the possible operations on it process. The front
end changes by Messages coming in, being processed and moving the
state of the World forward.
Next look at Render. This knows 2 things: how to turn the
World into a DOM, and how to give the user the ability to generate
Messages. It does not know how to process messages, and that’s an
important separation in the design.
Look at Virtual. This is a library of functions for creating a ReactJS-style virtual DOM, and applying it as the state of the world changes. Efficient, functional rendering.
Finally, Main wires everything together, ensure that the world is rendered and re-rendered as new messages advance the state of the world.
In a real app, the first two files would likely change vastly. This is where development effort would be spent: defining what to do, and how to display it.
The last two files should remain roughly the same, and will eventually be extracted into their own library.
- Ensure you have ghcjs installed.
make
- [X] Demonstrate Networking
- [ ] Demonstrate Forms
- [ ] Use Lucid for DOM-generation.
Copyright © 2014 Kris Jenkins
Distributed under the Eclipse Public License.