Friday, May 29, 2015
How to lazy load my file(js) on my Angularjs application
Before I want use RequireJS my Angularjs application, But I felling it very useful for me .
I find Oclazyload. It's very good,
Tuesday, May 26, 2015
Error: [$injector:unpr] Unknown provider: $templateRequestProvider <- $templateRequest <- $modal
Error: [$injector:unpr] Unknown provider: $templateRequestProvider <- $templateRequest <- $modal
http://errors.angularjs.org/1.2.28/$injector/unpr?p0=%24templateRequestProvider%20%3C-%20%24templateRequest%20%3C-%20%24modal
at VALIDITY_STATE_PROPERTY (http://localhost:8080/bower_components/angular/angular.js:78:14)
at http://localhost:8080/bower_components/angular/angular.js:3801:21
at Object.getService [as get] (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at http://localhost:8080/bower_components/angular/angular.js:3806:47
at getService (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at Object.invoke (http://localhost:8080/bower_components/angular/angular.js:3956:21)
at http://localhost:8080/bower_components/angular/angular.js:3807:39
at getService (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at invoke (http://localhost:8080/bower_components/angular/angular.js:3956:21)
at Object.instantiate (http://localhost:8080/bower_components/angular/angular.js:3976:25) <div class="container ng-scope" ng-view="">(anonymous function) @ angular.js:10126$get @ angular.js:7398nodeLinkFn @ angular.js:6755compositeLinkFn @ angular.js:6146publicLinkFn @ angular.js:6042$get.boundTranscludeFn @ angular.js:6166controllersBoundTransclude @ angular.js:6773update @ angular-route.js:865$get.Scope.$broadcast @ angular.js:13093(anonymous function) @ angular-route.js:547deferred.promise.then.wrappedCallback @ angular.js:11682deferred.promise.then.wrappedCallback @ angular.js:11682(anonymous function) @ angular.js:11768$get.Scope.$eval @ angular.js:12811$get.Scope.$digest @ angular.js:12623$get.Scope.$apply @ angular.js:12915done @ angular.js:8450completeRequest @ angular.js:8664xhr.onreadystatechange @ angular.js:8603
VM708:71 TooltipManager.cs: Processing http://localhost:8080/#/foundation/termcontent
TooltipBootstrapper.js:1 tooltipBootstrapper.cs: tt_process got a response of false
I use angular 1.2.28 and ui.bootstrap 0.12.1
If I use Jetty run my App on Chrome ,Then console will display 'Unknown provider: $templateRequestProvider <- $templateRequest <- $modal',But If I run my App on Safari will not display error.
I fell both difference at is use NodeJS.
When I update NodeJS from 0.12.3 to 0.12.4 and restart my MAC , finally Chrome not display error.
http://errors.angularjs.org/1.2.28/$injector/unpr?p0=%24templateRequestProvider%20%3C-%20%24templateRequest%20%3C-%20%24modal
at VALIDITY_STATE_PROPERTY (http://localhost:8080/bower_components/angular/angular.js:78:14)
at http://localhost:8080/bower_components/angular/angular.js:3801:21
at Object.getService [as get] (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at http://localhost:8080/bower_components/angular/angular.js:3806:47
at getService (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at Object.invoke (http://localhost:8080/bower_components/angular/angular.js:3956:21)
at http://localhost:8080/bower_components/angular/angular.js:3807:39
at getService (http://localhost:8080/bower_components/angular/angular.js:3929:41)
at invoke (http://localhost:8080/bower_components/angular/angular.js:3956:21)
at Object.instantiate (http://localhost:8080/bower_components/angular/angular.js:3976:25) <div class="container ng-scope" ng-view="">(anonymous function) @ angular.js:10126$get @ angular.js:7398nodeLinkFn @ angular.js:6755compositeLinkFn @ angular.js:6146publicLinkFn @ angular.js:6042$get.boundTranscludeFn @ angular.js:6166controllersBoundTransclude @ angular.js:6773update @ angular-route.js:865$get.Scope.$broadcast @ angular.js:13093(anonymous function) @ angular-route.js:547deferred.promise.then.wrappedCallback @ angular.js:11682deferred.promise.then.wrappedCallback @ angular.js:11682(anonymous function) @ angular.js:11768$get.Scope.$eval @ angular.js:12811$get.Scope.$digest @ angular.js:12623$get.Scope.$apply @ angular.js:12915done @ angular.js:8450completeRequest @ angular.js:8664xhr.onreadystatechange @ angular.js:8603
VM708:71 TooltipManager.cs: Processing http://localhost:8080/#/foundation/termcontent
TooltipBootstrapper.js:1 tooltipBootstrapper.cs: tt_process got a response of false
I use angular 1.2.28 and ui.bootstrap 0.12.1
If I use Jetty run my App on Chrome ,Then console will display 'Unknown provider: $templateRequestProvider <- $templateRequest <- $modal',But If I run my App on Safari will not display error.
I fell both difference at is use NodeJS.
When I update NodeJS from 0.12.3 to 0.12.4 and restart my MAC , finally Chrome not display error.
Error: [$injector:unpr] Unknown provider: $routeProvider
http://stackoverflow.com/questions/19197182/error-injectorunpr-unknown-provider-routeprovider?rq=1
It looks like you forgot to include the ngRoute module in your dependency for myApp.
In Angular 1.2, they've made ngRoute optional (so you can use third-party route providers, etc.) and you have to explicitly depend on it in modules, along with including the separate file.
'use strict';
angular.module('myApp', ['ngRoute']).
config(['$routeProvider', function($routeProvider) {
$routeProvider.otherwise({redirectTo: '/home'});
}]);
Tuesday, May 5, 2015
Jetty
http://localhost:8080/rest-api/
I want remove /rest-api/
/Users/chenxingjun/IdeaProjects/rest-api/pom.xml
add
I want remove /rest-api/
/Users/chenxingjun/IdeaProjects/rest-api/pom.xml
add
<contextPath>/</contextPath>
to
<plugin> <groupId>org.mortbay.jetty</groupId> <artifactId>maven-jetty-plugin</artifactId> <version>6.1.10</version> <configuration> <scanIntervalSeconds>10</scanIntervalSeconds> <contextPath>/</contextPath> <stopKey>foo</stopKey> <stopPort>9999</stopPort> </configuration> </plugin>
Sunday, May 3, 2015
Subscribe to:
Comments (Atom)