Reputation: 2558
I'm using adal-angular.js as part of my auth chain.
Everything works for pages that require auth. Pages that do not require auth will load, but they won't load any partials that are included in the view.
For example, the index.html
page has this:
<ng-include src="'/module/utility/view/footer.html'"></ng-include>
The footer only appears if the user is logged in.
I suspect my problem is similar to this bug report, but I'm not quite getting there.
I tried adding anonymousEndpoints
to my adal init, like so:
adalAuthenticationServiceProvider.init(
{
tenant: "xxx", // Optional by default, it sends common
clientId: "xxx", // Required
anonymousEndpoints: ['/app/module/utility/view/footer.html']
// also tried:
//anonymousEndpoints: ['/app/module/utility/view/']
//anonymousEndpoints: ['/']
//and soforth.
},
$httpProvider
);
Still no footer. Also, no errors.
Any help?
Upvotes: 0
Views: 129
Reputation: 2558
Okay, so the answer was pretty simple.
What little documentation there is on this problem suggests this:
anonymousEndpoints: ['/app/module/utility/view/']
That didn't work for me. This did:
anonymousEndpoints: ['/module/utility/view/footer.html']
The path needs to be relative to app.js, which for me is in the app folder.
Upvotes: 1