How to add source code comments in Thymeleaf templates that don't get included in generated HTML?

前端 未结 5 1748
無奈伤痛
無奈伤痛 2021-02-03 18:14

I am using full stack Thymeleaf (spring mvc, security, layout dialect, webflow) in a mid-size web application.

Ok..now that we put so much of code in the html templates

5条回答
  •  爱一瞬间的悲伤
    2021-02-03 18:25

    With Thymeleaf 3.0, the currently working version was

    
       this comment will be removed by thymeleaf on the template processing
    
    

    Other answers, for earlier thymeleaf versions, did not work by me. The current thymeleaf documentation is here.

提交回复
热议问题