Book Image

Grunt Cookbook

By : Jurie-Jan Botha
Book Image

Grunt Cookbook

By: Jurie-Jan Botha

Overview of this book

<p>A web application can quickly turn into a complex orchestration of many smaller components, each one requiring its own bit of maintenance. Grunt allows you to automate all the repetitive tasks required to get everything working together by using JavaScript, the most popular programming language.</p> <p>Grunt Cookbook offers a host of easy-to-follow recipes for automating repetitive tasks in your web application's development, management, and deployment processes. This book will introduce you to methods that can be used to automate basic processes and your favorite tools. By following the recipes, you will soon be comfortable using Grunt to perform a wide array of advanced tasks in a range of different scenarios.</p>
Table of Contents (17 chapters)
Grunt Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Introduction


The generation of content by combining logic and data poses a unique set of problems, and template engines are specifically designed to solve them. In this chapter, we'll mostly be focusing on generating HTML using various template engines, even though some of them are designed in such a way as to allow for the generation of pretty much any type of readable file format.

Even though many of the more feature-rich web application frameworks available in the JavaScript community provide for the on-demand compilation, rendering and caching of templates, doing so using Grunt provides for the flexibility required in building a highly optimized and specialized solution. Templates can be rendered directly to HTML or compiled to JSTs that can be used directly without any extra processing. The products of these templates can also be packaged to be made available in pretty much any environment you might want to use them in.

At the time of writing, there are many great templating engines available...