Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add angular 5 and replace AuthHttp with new Http Interceptor #77

Merged
merged 7 commits into from
Aug 4, 2022

Conversation

rjwijnen
Copy link

Yesterday i tried to make the library work on Angular 5 and use the new HttpClient. As i saw a lot of other library's changed to the http interceptor for adding the auth. token. I tried to implement the logic from the old Auth Http into a new Interceptor. I hope some of you can double check everything is working?

This was referenced Nov 30, 2017
@Lejdholt
Copy link

Lejdholt commented Dec 7, 2017

can't say if the implementation of the interceptor is correct or not, but i want it

@riisi
Copy link

riisi commented Jan 9, 2018

Also looking to use this...

Copy link

@hkusulja hkusulja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I confirm this for Angular 5

@hkusulja
Copy link

@sureshchahal almost two months passed, any info about merge for Angular 5 (current) support? Tx

@@ -0,0 +1,3145 @@
{

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rjwijnen you should probably not be pushing this file in.

@claudiuconstantin
Copy link

What's the status for this one?

@Mctalian
Copy link

Mctalian commented Jan 26, 2018

I have leveraged the AuthHttpInterceptor that is provided in this PR in my own project (copy and paste) and I can confirm that it works.

From what I see, there might just be a webpack warning due to dynamic requires if you were to try to use this with Angular 5, but this would at least enable folks to continue using this library with Angular 5.

Great work @rjwijnen , much appreciated!

@rjwijnen
Copy link
Author

@ranveeraggarwal i removed the package lock.

@rjwijnen
Copy link
Author

rjwijnen commented Feb 8, 2018

@sureshchahal could you look at this pull request and push it to master and NPM?

@jmtrz
Copy link

jmtrz commented Jun 27, 2018

Hi Is this already fix i am getting this error

WARNING in ./node_modules/ng2-adal/node_modules/@angular/core/@angular/core.es5.js
5659:15-36 Critical dependency: the request of a dependency is an expression

WARNING in ./node_modules/ng2-adal/node_modules/@angular/core/@angular/core.es5.js
5675:15-102 Critical dependency: the request of a dependency is an expression

If already fxed may i know how will i implement it in my proj 👍 tnx

@saransh944
Copy link

@rjwijnen can you please create your own project for the version 5 changes and host it on NPM? Looks like @sureshchahal is not active on this anymore.

@sureshchahal
Copy link
Owner

sureshchahal commented Aug 7, 2018 via email

@saransh944
Copy link

Thanks for the response @sureshchahal . Just a quick note, a lot of users of this repo including myself reviewed the changes by @rjwijnen and everything looks good. Is it possible for you to merge this change?

@rjwijnen
Copy link
Author

@saransh944 in the meantime i switched to https://github.com/benbaran/adal-angular4 ..

@saransh944
Copy link

@rjwijnen , thanks for the suggestion. Since we are talking about this, how are you handling the behavior that happens after the token is refreshed? I have noticed whenever the token refreshes, app is initialized 2-3 times, also Angular change detection does not work properly, i.e. ngModule breaks, @input changes from parent to child component doesn't propagate, etc. I am deleting the adal iFrame that gets created for the token refresh in case that is the reason for this weird behavior, but still I'm seeing these glitches. Do you have any recommendations on that?

@sureshchahal sureshchahal merged commit 33ef768 into sureshchahal:master Aug 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.