Repository navigation
Android Capacitor app: keycloak.init().then promise does not resolve after a successful login #20124
Unanswered
NinaDenisova
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Hello,
I am using keycloak v 21.0.1. I use keycloak-js. I have the following code for keycloak login:
keycloak. => {...}
keycloak.init({
onLoad: 'login-required',
pkceMethod: "S256",
checkLoginIframe: false,
}).then((authenticated: boolean) => {...}.catch(err){....}
When run on web, when a call to redirectUri is received after a successful login, "then" block is called and also onAuthSuccess is invoked.
When run on the capacitor app on Android, the keycloak login is shown and the login succeeds. I can see my session in keycloak admin UI. Also, I receive the redirectUrl and the app, configured to activate on the redirect Url, does become active. But "then" block is not invoked and event does not get invoked.
All reactions