I\'m following this tutorial: http://www.thymeleaf.org/doc/layouts.html (got to Thymeleaf Layout Dialect section). In there you can find an example:
I think I found a slightly less verbose way to for using th:replace
and th:fragment
together, e.g. to include common metadata and static resource includes in your pages.
Put the th:remove="tag"
in the fragment definition, so you don't have to repeat the th:remove="tag"
everytime including it.
fragment_head.html
mypage.html