You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to provide place holders for content in my layout template that I can implement in my child templates. I have tried everything I can think of but I can only specify string values to be placed in the place holders and not complete html sections.
layout
doctype 5
html lang: 'en', ->
head ->
title "#{@title} - Site" if @title?
@headsection if @headsection?
body ->
p 'some content'
@body
As maurice once said, this functionality is usually implemented in frameworks, but you should be able to do it now. At least, in a flatiron plugin I created called creamer I am able to accomplish it, by sub dividing my template into local functions. See my test example:
I want to provide place holders for content in my layout template that I can implement in my child templates. I have tried everything I can think of but I can only specify string values to be placed in the place holders and not complete html sections.
layout
child template
The text was updated successfully, but these errors were encountered: