Use this helper in a "parent" layout:
See nested layouts.
Using the indent
hash option:
Template: index.hbs
Renders to:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
<h1>My Blog</h1>
<h2>Post of the day</h2>
<p>
Vestibulum posuere, quam sed bibendum posuere
Pellentesque habitant morbi tristique senectus
Pellentesque nulla augue, volutpat vitae
</p>
<a href="#">Read more...</a>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<!-- code comment -->
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
<h1>My Blog</h1>
<h2>Post of the day</h2>
<!-- scripts -->
<a href="#">Read more...</a>
</body>
</html>
Example output with condensed: true
:
<!DOCTYPE html>
<html lang="en">
<head>
<!-- code comment -->
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
<h1>My Blog</h1>
<h2>Post of the day</h2>
<!-- scripts -->
<a href="#">Read more...</a>
</body>
</html>
When used with condense
, defining padcomments: true
will result in something like this:
<!DOCTYPE html>
<html lang="en">
<head>
<!-- code comment -->
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
<h1>My Blog</h1>
<h2>Post of the day</h2>
<!-- scripts -->
<a href="#">Read more...</a>
</body>
</html>