O'Reilly logo

Grunt Cookbook by Jurie-Jan Botha

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Generating pages from a collection

In case we've got a collection of items in our site data, we might very well want to generate some pages using that collection. A site that displays blog posts, for instance, would probably want an individual page generated for each post in the collection of posts.

Getting started

In this recipe we'll be continuing work on the project from the Creating and using a site layout recipe in this chapter. Be sure to refer to it if you are not yet familiar with it's content. Before we start we should also make sure that the site builder and server are running. If they aren't yet running they can be started using the grunt server command.

How to do it...

The following steps take us through creating a data file that contains ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required