javascript - Grails GSP and template relations -
javascript - Grails GSP and template relations -
when have gsp , seek render template part of it, if template sophisticated plenty has have own css , js, best place set template's css , js? have inline template's markup in same file such sense belongs parent gsp's css , js maybe in same files? suggestions?
so right parent gsp looks this.
<head> reference external file has parent gsp's css inline js </head> <body> ... </body>
and template render later gsp looks this:
inline css inline js inline markup
i know isn't cleanest, best strategy hence seek input is. thanks.
the reply "it depends". depends on how using template.
more reusing template? if so, makes more sense set required css , js within template it's self contained , reusable in such manner.
if using template partial rendering then, , within specific parent gsp makes more sense include css , js within parent gsp , not template.
javascript css templates grails
Comments
Post a Comment