How to use angular-route - 2 common examples

To help you get started, we’ve selected a few angular-route examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github edokeh / klog / public / js / app.js View on Github external
define(function(require, exports, module) {
    var angular = require('angularjs');
    var ngAnimate = require('angular-animate');
    var ngResource = require('angular-resource');
    var ngRoute = require('angular-route');
    var ngSanitize = require('angular-sanitize');
    var SeajsLazyAngular = require('seajs-lazy-angular');
    var bootstrap = require('bootstrap/index');
    var nav = require('./nav/index');
    var common = require('./common/index');

    var admin = angular.module('admin', [
        ngAnimate.name,
        ngRoute.name,
        ngResource.name,
        ngSanitize.name,
        nav.name,
        bootstrap.name,
        common.name
    ]);

    admin.config(SeajsLazyAngular.cacheInternals);
    SeajsLazyAngular.patchAngular();
    SeajsLazyAngular.setResolveCallback(['$rootScope', 'controller', function($rootScope, controller) {
        $rootScope.title = controller.title + ' - Klog 后台管理';
    }]);

    admin.config(['$routeProvider', function($routeProvider) {

        var blog = SeajsLazyAngular.createLazyStub('/js/blog/index');
github edokeh / klog2 / app / assets / javascripts / sea-modules / angular / angularjs-all / src / index.js View on Github external
define(function(require) {
    var angular = require('angularjs');
    var ngAnimate = require('angular-animate');
    var ngResource = require('angular-resource');
    var ngRoute = require('angular-route');
    var ngSanitize = require('angular-sanitize');

    var angularjsAll = angular.module('ngAll', [
        ngAnimate.name,
        ngRoute.name,
        ngResource.name,
        ngSanitize.name
    ]);

    return angular;
});

angular-route

AngularJS router module

MIT
Latest version published 3 years ago

Package Health Score

64 / 100
Full package analysis

Popular angular-route functions