I don't claim to be very knowledgeable in these things, there is a high chance i am might be doing something wrong.
In Short:
Adal uses an IFrame to make fetch the token, the whole angular2 app is loaded in that IFrame.
I suspect that interferes with the binding. My example shows 3 bindings:
a list binded to Observable<any[]> using async with an aquire token requst
a list binded to Observable<any[]> using async and NO aquire token request
a list binded to string[] with an aquire token request
Scenarios
1.Open a new tab
On opening the app, after the authentication step and the redirect back to the /oic route, the 3 bidings from above behave in the following way:
does not work
works
works only if the manual refresh ChangeDetectorRef.detectChanges() is in place
(you can also see in the console that the app is loaded in the IFrame as well.)
2.Refresh
On refreshing the app, having the token cached, there is no redirect to the /oic route and the 3 bindings behave in the following way:
Issue
I was playing around with angular2 and adal and found this scenario where using aquire token causes bindings to Observable<any[]> to not work.
I've uploaded a sample of what I found here.
I don't claim to be very knowledgeable in these things, there is a high chance i am might be doing something wrong.
In Short:
Adal uses an IFrame to make fetch the token, the whole angular2 app is loaded in that IFrame. I suspect that interferes with the binding. My example shows 3 bindings:
Scenarios
1.Open a new tab
On opening the app, after the authentication step and the redirect back to the /oic route, the 3 bidings from above behave in the following way:
(you can also see in the console that the app is loaded in the IFrame as well.)
2.Refresh
On refreshing the app, having the token cached, there is no redirect to the /oic route and the 3 bindings behave in the following way: