Skip to content

Latest commit

 

History

History
52 lines (43 loc) · 1.21 KB

README.md

File metadata and controls

52 lines (43 loc) · 1.21 KB

dashboard

This project is generated with yo angular generator version 0.15.1.

Build & development

Run grunt for building and grunt serve for preview.

Testing

Running grunt test will run the unit tests with karma.

Development

Install yo, grunt-cli, bower, generator-angular and generator-karma:

npm install -g grunt-cli bower yo generator-karma generator-angular

Route

Generates a controller and view, and configures a route in app/scripts/app.js connecting them.

Example:

yo angular:route myroute

Produces app/scripts/controllers/myroute.js:

angular.module('myMod').controller('MyrouteCtrl', function ($scope) {
  // ...
});

Produces app/views/myroute.html:

<p>This is the myroute view</p>

Configures a route in app/scripts/app.js connecting them.

.when('/myroute', {
  templateUrl: 'views/myroute.html',
  controller: 'MyrouteCtrl',
  controllerAs: 'myroute'
})

Generates test test/spec/controllers/myroute.js:

describe('Controller: MyrouteCtrl', function () {
  // ...
}

For more AngularJS generator see https://github.com/yeoman/generator-angular.