Skip to content

Instantly share code, notes, and snippets.

@brandonroberts
Created February 19, 2016 21:37
Show Gist options
  • Save brandonroberts/d8bc9bb893734fc86d3b to your computer and use it in GitHub Desktop.
Save brandonroberts/d8bc9bb893734fc86d3b to your computer and use it in GitHub Desktop.
Component Router Lazy Loading
(function() {
var user = angular.module('user', []);
user.component('user', {
template: 'User <br><br><ng-outlet></ng-outlet>',
$routeConfig: [
{ path: '/profile', name: 'Profile', component: 'userProfile' }
]
});
user.component('userProfile', {
template: 'Profile'
});
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment