顿搜
飞过闲红千叶,夕岸在哪
类目归类
'use strict';
var app = angular.module('app', [
'ngAnimate',
'ngCookies',
'ngStorage',
'app.controllers',
'msgbox'
])
app.config(
['$stateProvider', '$urlRouterProvider', '$controllerProvider', '$compileProvider', '$filterProvider', '$provide',
function ($stateProvider, $urlRouterProvider, $controllerProvider, $compileProvider, $filterProvider, $provide) {
app.controller = $controllerProvider.register;
app.directive = $compileProvider.directive;
app.filter = $filterProvider.register;
app.factory = $provide.factory;
app.service = $provide.service;
app.constant = $provide.constant;
app.value = $provide.value;
$urlRouterProvider
.otherwise('/app/');
$stateProvider
.state('app', {
abstract: true,
url: '/app',
templateUrl: 'tpl/app.html',
resolve: {
deps: ['uiLoad',
function (uiLoad) {
return uiLoad.load([
'css/bootstrap.css',
'js/libs/moment.min.js'
]);
}]
}
})
.state('home', {
url: '/home',
template: '<div ui-view class="fade-in-right-big smooth">Hello word</div>'
})
}
]
)<a ui-sref="home">Home</a>