开发者

Wicket: hide comments in HTML

开发者 https://www.devze.com 2023-03-21 03:56 出处:网络
JSPs support the <%-- comment --%> syntax for comments, which 开发者_开发百科is a way to comment markup code such that it doesn\'t get included in the emitted HTML.

JSPs support the <%-- comment --%> syntax for comments, which 开发者_开发百科is a way to comment markup code such that it doesn't get included in the emitted HTML.

Is there a way to do this in Wicket?


<wicket:remove> is your friend. Wicket will remove this from output.

See here https://cwiki.apache.org/confluence/display/WICKET/Wicket's+XHTML+tags#Wicket%27sXHTMLtags-Elementwicket%3Aremove


there's

Application#getMarkupSettings().setStripComments(true) 

which will remove

<!-- comment --> 

from your markup

0

精彩评论

暂无评论...
验证码 换一张
取 消