So you have this typical static site built with Yeoman. You probably duplicated your layout for each of the pages you sites contains. So you probably wondered how to actually include some partials and DRY up these pages.
Since Yeoman is loading all the available tasks from the top of your grunt file, there is no need to import the bake tasks anymore.
Bake actually has a lot more tasks that we need for this simple example, so I’ll let you discover the rest.
Update you grunt.js file
First, create a bake task inside you grunt config.
Since you need to include the partials before usemin take actions on the index.html to concatenate you assets, you need to rename your index.html to base.html
Next, edit you server task:
Now this will includes the partials in base.html to index.html and then will be moved to the temp directory for livereload to watch.
You also need to do somehting similar for the build task, make sure the bake task happens before the useminPrepare:
Now to make livereload catch your changes you need to add the folder where you want it to watch your partials. In our case we’ll use app/includes: