| Copyright | (C) 2016-2025 David M. Johnson |
|---|---|
| License | BSD3-style (see the file LICENSE) |
| Maintainer | David M. Johnson <code@dmj.io> |
| Stability | experimental |
| Portability | non-portable |
| Safe Haskell | None |
| Language | Haskell2010 |
Miso.Reload
Contents
Description
Support for live-reload of miso applications.
Live reload
Clears the body and head on each reload.
Meant to be used with WASM browser mode.
This function executes an IO action, clearing both the body and head
of the current page in the process.
main :: IO () main = reload (startApp defaultEvents app)
N.B. This also resets the internal component state. This means all currently
mounted components become unmounted and ComponentId are reset to their
original form factory.
Since: 1.9.0.0