📄️ Getting started
Start with the depicted file structure with main.go at the root of the project.
📄️ Static files
You can use any web server you like, however the examples will be using http.ServeMux from the standard library.
📄️ Middleware
FnComponents are rendered by directing http requests through a special middleware function.
📄️ Web server
By adding fncmp.MiddlewareFn to the '/main' endpoint, we can now serve our index page, as well as the button.
📄️ Event listeners
A fncmp.HandleFn can also be used as a callback function for an event listener.
📄️ Rendering
This section will cover how rendering is achieved and how we'll use FnComponent's methods to create a to-do list.
📄️ Context
The context passed to a HandleFn contains a Dispatch struct