Simple Scaffolding with the Ignite UI Yeoman Generator

Ambrose Little / Tuesday, January 28, 2014

If you haven’t heard of Yeoman, I gladly recommend you check it out. It’s a nifty little CLI-based scaffolding tool for modern Web apps.


Yeoman

One of the nifty things about it is that their generator (scaffolding) architecture is extensible, so anybody can add to it, and many have, such as the popular Angular generator. And now we have a simple one ready for you to use with Ignite UI.

Because Ignite UI is not an application framework (like Angular, Ember, Backbone, etc.), it didn’t seem to make a lot of sense for us to presume to set up a whole project for you. Instead, you can use whatever your preferred project generator is (such as the basic “webapp” one) to generate your app, and then you can use the Ignite UI generator to augment it. (Or you can use it on its own inside pretty much any project.)

So What Do You Get?

Well, for this initial release, I thought I’d keep it super simple but try to be somewhat helpful, so what you get is a single HTML page that has the Ignite UI boilerplate built in for you, plus a bonus of two nifty samples that illustrate using the Ignite UI Data Chart and the Ignite UI Grid based on some simple JSON data.

The code is well-commented, so you can see which parts you can and should safely gut/modify/replace with your own. As I said, I wanted to keep it simple for this initial release, and let the generator options organically grow from there.

So check it out. The instructions for using it are on the generator-igniteui GitHub repo. Once you have it installed, you can just type yo igniteui wherever you want to add a new page that uses Ignite UI.

If you have suggestions for what you’d like to see added as generator options/sub-generators (or have other issues), please report them on the repo.

Enjoy!