Authorization flow with OpenId connect/Aouth2
8tesla8 / angular-oidc Goto Github PK
View Code? Open in Web Editor NEWangular and OpenID Connect
angular and OpenID Connect
Hello
I am trying to use the code , But I am getting CORS error as well as 404
It seems if using Angular routing callback (eg silent renew) to component (SilentCallbackComponent) it will load a new app in iframe
The _authService will be a new instance and logic will not be able to apply to the original/main app.
Do you have same issue?
The only way I can get around this is handle callback using html instead of angular component.
But it mean if I want to do any logic after renew is complete, I can no long use automaticSilentRenew feature, and I have to subscribe to addAccessTokenExpiring event and do the signinSilent() myself
core.js:6210 ERROR Error: Uncaught (in promise): NullInjectorError: R3InjectorError(AppModule)[InjectionToken IUrlConstantService injection token -> InjectionToken IUrlConstantService injection token -> InjectionToken IUrlConstantService injection token]:
NullInjectorError: No provider for InjectionToken IUrlConstantService injection token!
NullInjectorError: R3InjectorError(AppModule)[InjectionToken IUrlConstantService injection token -> InjectionToken IUrlConstantService injection token -> InjectionToken IUrlConstantService injection token]:
NullInjectorError: No provider for InjectionToken IUrlConstantService injection token!
at NullInjector.get (vendor.js:29508:27)
at R3Injector.get (vendor.js:29675:33)
at R3Injector.get (vendor.js:29675:33)
at R3Injector.get (vendor.js:29675:33)
at NgModuleRef$1.get (vendor.js:43705:33)
at Object.get (vendor.js:43419:35)
at lookupTokenUsingModuleInjector (vendor.js:21795:39)
at getOrCreateInjectable (vendor.js:21907:12)
at Module.ɵɵdirectiveInject (vendor.js:33099:12)
at NodeInjectorFactory.LogoutCallbackComponent_Factory [as factory] (main.js:407:183)
at resolvePromise (polyfills.js:10606:31)
at resolvePromise (polyfills.js:10560:17)
at polyfills.js:10672:17
at ZoneDelegate.invokeTask (polyfills.js:9799:31)
at Object.onInvokeTask (vendor.js:46946:33)
at ZoneDelegate.invokeTask (polyfills.js:9798:60)
at Zone.runTask (polyfills.js:9571:47)
at drainMicroTaskQueue (polyfills.js:9975:35)
at ZoneTask.invokeTask [as invoke] (polyfills.js:9884:
Can anyone help me how to fix this?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.