Is there a way to do gsp partials rather than tag libraries?

こ雲淡風輕ζ 提交于 2019-12-10 21:43:53

问题


One of the things I liked about freemarker is that you can quickly create new macros that encapsulate complex html to make the pages smaller and more concise. Do I have to make tag libraries to do the same thing in grails, or is there a really light-weight syntax for achieving the same thing?


回答1:


There is a <g:render> tag, which may match your needs. It's documented here.



来源:https://stackoverflow.com/questions/2903353/is-there-a-way-to-do-gsp-partials-rather-than-tag-libraries

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!