+Hiccup provides the some built in elements that we can use out of the box. The `hiccup.page/doctype` function, for instance, can be used to generate the doctype for an HTML5 page. We can use the `hiccup2.core/html` function to generate the final HTML (HTML escaping by default was only introduced in Hiccup 2...but better late than never! For this reason, use the `hiccup2.core/html` function instead of the `hiccup.core/html` function which is still included for compatibility reasons). The `hiccup2.core/html` emits a `raw string` that we can then transform to a string with the `str` function. We can now write a function that will be a reusable page template!
0 commit comments