Book Image

Learning Yeoman

By : Jonathan Spratley
Book Image

Learning Yeoman

By: Jonathan Spratley

Overview of this book

Table of Contents (17 chapters)
Learning Yeoman
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Free Chapter
1
Modern Workflows for Modern Webapps
Index

Yo – generators


What makes Yeoman amazing are the generators. There is a robust set of templates (commonly referred to as generators) for any type of project. Finding a generator to install and use is quite simple as well; just use the npm search generator-[name] command to search for a generator where the name matches.

The Yeoman workflow

The general workflow to follow when using Yo, Bower, and Grunt is as follows:

  1. Install a generator as follows:

    $ npm install generator-[name]
    
  2. Scaffold a project:

    $ yo [generator] [args] [options]
    
  3. Install a dependency:

    $ bower install [dependency#version] [options]
    
  4. Test the project:

    $ grunt test
    
  5. Preview the project:

    $ grunt serve
    
  6. Build the project for deployment:

    $ grunt
    

Official generators

Here is a list of the official generators maintained by the Yeoman team. Use these as a base to create a custom generator or to create a project:

  • polymer: This is a generator used to create Polymer webapps and components

  • chromeapp: This is a generator used to create a Google...