Comment

Comment by cosmic_quanta

I love parser combinators. It's a much more natural 'format' than parsing with regular expressions which I have to do at $DAY_JOB.

One aspect that I see discussed less often is the idea of 'builder combinators', which are kind of the inverse of parser combinators. There are multiple libraries in Haskell which make it very easy to write HTML/SVG/... this way:

https://hackage.haskell.org/package/blaze-html

https://hackage.haskell.org/package/blaze-svg

I haven't needed to do the same with SQL but I imagine that this already exists as well

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton