以下是我的app.js
.sliding-box {
position: absolute;
left: 10px;
top: 10px;
}
.sliding-box img {
position: absolute;
height: 180px;
}
/* I know that the following is not pretty and can be probably done */
/* in a more elegant manner */
#img1 {
}
#img2 {
left: 300px;
}
#img3 {
left: 600px;
}
#img4 {
left: 946px;
}
#img5 {
left: 1280px;
}
这是我的观点或索引页面的一部分
var appAcademia = angular.module("appAcademia", ['ui.router', 'ngResource' ,'localStorageModule']);
appAcademia.config(function ($stateProvider, $urlRouterProvider, resourceProvider,$httpProvider) {
$httpProvider.interceptors.push('authInterceptorService');
$urlRouterProvider.otherwise('/home');
$stateProvider
.state('home', {
url: '/home',
templateUrl: '/Home/Home',
controller: 'HomeController',
controllerAs: 'vm',
})
.state('about', {
// we'll get to this in a bit
});
});
var authServiceBase = 'http://localhost:12019/';
var resourceServiceBase = 'http://localhost:12007/';
appAcademia.constant('ngAuthSettings', {
apiAuthServiceBaseUri: authServiceBase,
apiResourceServiceBaseUri: resourceServiceBase,
clientId: '414e1927a3884f68abc79f7283837fd1'
}); appAcademia.run(['authService', function (authService) {
authService.fillAuthData();
}]);
这是我得到的错误。
<body class="preview" id="top" data-spy="scroll" data-target=".subnav" data-offset="80" data-ng-app="appAcademia">
现在我的模块名称是appAcademia。那么我怎么会得到上述错误?模块&应用程序&#39;在哪里?来自(哪里? 现在这里是最离奇的部分。
Uncaught Error: [$injector:nomod] Module 'App' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
让我补充说,所有依赖模块都已创建但从未加载