Closed swiftone closed 4 years ago
Added and restarted
Sahweet! Tests pass!! 🎉
@swiftone I updated my branch to use /login/callback
and upgrade to Angular 10.1. Should I create a new PR or are you able to merge those changes into this one?
@mraible - Assuming I git'ted correctly, your changes should now be in here, let me know if anything is missing.
@swiftone I noticed that the current custom login example has the following:
const oktaConfig = Object.assign({
onAuthRequired: ({oktaAuth, router}) => {
// Redirect the user to your custom login page
router.navigate(['/login']);
}
}, sampleConfig.oidc);
However, the Angular SDK docs seem to indicate it should be:
const oktaConfig = Object.assign({
onAuthRequired: (oktaAuth, injector) => {
const router = injector.get(Router);
// Redirect the user to your custom login page
router.navigate(['/login']);
}
}, sampleConfig.oidc);
Which one is correct?
@mraible the second one. The first argument is the Okta auth service, the second argument is the Angular injector (this changed in okta-angular 2.0 I think)
@aarongranick-okta In that case, can you please include this commit in this PR.
@swiftone Can you please try adding
http://localhost:8080/callback
as a login redirect URI to the app on https://samples-javascript.okta.com and restarting the job in Travis?