News for hackers. Stuff that matters.
Re:Writing HTML with Racket and X-Expressions (2019) by state_less on Wednesday April 01, 2020 @05:04AM (#22746927)
You can avoid parens and have some fun building up HTML with combinators.

  > numbers n = docTypeHtml $ do
  >     H.head $ do
  >         H.title "Natural numbers"
  >     body $ do
  >         p "A list of natural numbers:"
  >         ul $ forM_ [1 .. n] (li . toHtml)
https://jaspervdj.be/blaze/tutorial.html

There are no comments on this comment yet.