ema: Static site generator library with hot reload

[ agpl, library, program, web ] [ Propose Tags ]

Ema is a next-gen Haskell library for building jamstack-style static sites. Ema sites are change-aware; in addition to good ol’ static site generation, it provides a live server supporting fast hot-reload in the browser on code or data change.

[Skip to Readme]
Versions [RSS] [faq]
Change log CHANGELOG.md
Dependencies aeson, async, base (>= && <=, blaze-html, blaze-markup, commonmark, commonmark-extensions, commonmark-pandoc, containers, data-default, directory, ema, filepath, filepattern, fsnotify, http-types, lvar, monad-logger, monad-logger-extras, neat-interpolation, optparse-applicative, pandoc-types, profunctors, relude, safe-exceptions, shower, stm, tagged, text, time, unliftio, wai, wai-middleware-static, wai-websockets, warp, websockets [details]
License AGPL-3.0-only
Copyright 2021 Sridhar Ratnakumar
Author Sridhar Ratnakumar
Maintainer srid@srid.ca
Category Web
Home page https://ema.srid.ca/
Bug tracker https://github.com/srid/ema/issues
Uploaded by sridca at 2021-04-26T18:27:16Z
Distributions NixOS:
Executables ema-docs
Downloads 27 total (2 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs not available [build log]
All reported builds failed as of 2021-05-29 [all 2 reports]


  • Ema
    • Ema.CLI
    • Example
      • Ema.Example.Ex01_HelloWorld
      • Ema.Example.Ex02_Clock
      • Ema.Example.Ex03_Documentation
    • Helper
      • Ema.Helper.FileSystem
      • Ema.Helper.Tailwind



Include examples and their dependencies


Include helper modules based on blaze-html


Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info


Maintainer's Corner

For package maintainers and hackage trustees


Readme for ema-

[back to package description]


Ema is a next-gen Haskell library for building jamstack-style static sites, with fast hot reload. See ema.srid.ca for further information.

The simplest Ema app looks like this:

main :: IO ()
main = do
  let name :: Text = "Ema"
  runEmaPure $ \_ ->
    encodeUtf8 $ "<b>Hello</b>, from " <> name


Run bin/run (or Ctrl+Shift+B in VSCode). This runs the documentation example; modify ./.ghcid to run a different example, such as the clock example - which updates every second, demonstrating hot reload.