why can '{{ content }}' be used in Jekyll templates
Last Updated:2022-08-12
#Question: why can '{{ content }}' be used in Jekyll templates?
that is because content
is a special variable in all templates.
The content variable holds the page/post content including any sub-template content previously defined.
Render the content
variable wherever you want into your template
Example Usage:
<body>
<div id="sidebar"> ... </div>
<div id="main"> {% raw %}
{{ content }}{% endraw %}
</div>
</body>
See more?Go to this site where I figured out the answer to the question.