Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Question on theme development

Started by Muut Archive 10 years ago · 2 replies · 375 views
10 years ago

I am interested in working with bootstrap + Grav and am curious if there is a reason why I would not want to add bootstrap code inside my template files.

For example I am setting up a hidden global folder to create widgets for different places in my theme like the header area. In my inheritance theme I am modifying the the base.html.twig file like the following which includes the bootstrap column classes. I am interested in any thoughts on setting things up this way and if it may be something that I should not be doing.

<header id="header">
<div class="container">
<div class="row">
<div id="logo" class="col-md-2">
<h3><a href="{{ base_url == '' ? '/' : base_url }}">{{ config.site.title }}</a></h3>
</div>
<div id="header-widget" class="col-md-10">
{{ page.find('/_global/HeaderWidget').content }}</div>
</div>
</div>
</header>

Thank You.

10 years ago

flaviocopes,

Thanks, that is a good idea.

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1368 9 years ago
Archive · by Muut Archive, 9 years ago
2 940 9 years ago
Archive · by Muut Archive, 9 years ago
2 4069 9 years ago
Archive · by Muut Archive, 9 years ago
1 2960 9 years ago
Archive · by Muut Archive, 9 years ago
3 1125 9 years ago