angularjs - AOT compiled code throws error - No provider for t -
i getting following error when run angular application. front end in angular , back-end uses spring.
build.js:1 **exception: uncaught (in promise): error: no provider t! error: no provider t!** @ e [as constructor] (http://localhost:8080/xo-as/ng/build.js:1:59315) @ e [as constructor] (http://localhost:8080/xo-as/ng/build.js:1:60416) @ new e (http://localhost:8080/xo-as/ng/build.js:1:60744) @ t._throwornull (http://localhost:8080/xo-as/ng/build.js:1:71064) @ t._getbykeydefault (http://localhost:8080/xo-as/ng/build.js:1:71402) @ t._getbykey (http://localhost:8080/xo-as/ng/build.js:1:70782) @ t.get (http://localhost:8080/xo-as/ng/build.js:1:69150) @ e.get (http://localhost:8080/xo-as/ng/build.js:1:126499) @ e.t.injectorget (http://localhost:8080/xo-as/ng/build.js:1:152798) @ e.get (
when researched online solutions came across few posts mentioned because of cookieoptions.
in following link, have suggested solutions well.
https://github.com/salemdar/angular2-cookie/issues/37
and tried following:
import { cookieservice } 'angular2-cookie/services/cookies.service'; import { cookieservice, cookieoptions } 'angular2-cookie/core';
when build getting error message saying 'cookieservice' not exported 'node_modules/angular2-cookie/services/cookies.service.js'
what supposed import properly? please let me know if need provide other information?
edit : able import cookieoptions using following
import { cookieservice, cookieoptions } 'ngx-cookie';
but still when run application getting error
error: no provider t! @ e [as constructor]
angular2-cookie
deprecated. should use ngx-cookie.
Comments
Post a Comment