4 ms·
You should check out Elm[0] if you haven’t already. It’s also worth noting that things like JSX and Vue templates are just syntactic sugar over render functions
by deergomoo 6y ago
You should check out Elm[0] if you haven’t already. It’s also worth noting that things like JSX and Vue templates are just syntactic sugar over render functions that look very similar to the example you gave (albeit less terse).
John Sundell also has a Swift DSL[1] for generating HTML in a similar fashion, though Swift on the server is still very niche.
Obviously these all still ultimately produce HTML, but they do offer some nice accordances for the developer.
[0]: https://guide.elm-lang.org/ https://guide.elm-lang.org/
[1]: https://github.com/JohnSundell/Plot https://github.com/JohnSundell/Plot