This repository has been archived by the owner on Jun 26, 2021. It is now read-only.
anonymousEndpoints feature with interceptor enabled fails with loading 2 templateUrls at once #345
Labels
Milestone
Running adal and adal-angular with ui-router introduces a problem.
When states have templateUrls defined, and you jump from level 1 state, into a nested level 3 state, two templates need to be loaded first. In my case
/host-application/module-container.html
and/modules/vacation/views/list.html
While some stuff in adal-angular pushes the
/modules/vacation/views/list.html
url into the anonymousEndpoints array, adal.js at about line 748 checks for the resource of/host-application/module-container.html
, which hasn't been added to anonymousEndpoints yet, marking it asconfig.loginResource
.The stateChange is not triggered, because it waits for the template to be resolved, therefor the login doesn't trigger, which is supposed to continue the delayed call for the template. So it's kind of a deadlock situation:
The router waits for the template, the template waits for the login, the login waits for the stateChange in the router.
Heres a screenshot. I do not have time to make a minimal reproduction project.
The scenario in the screenshot is navigating from the state
landingpage
(templateUrl: "/host-application/landingpage.html") to the statemodules.vacation.list
(templateUrl: "/modules/vacation/views/list.html")The extra layer from state
modules.vacation
doesn't require a call, as its template is defined statically:The text was updated successfully, but these errors were encountered: