-
Notifications
You must be signed in to change notification settings - Fork 50
Feature/add openUrl support #393
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
allowInterop can be used multiple times on the same function without adverse effects, so it is ok if the user also passes a function that has already been "interoped"
@Widcket @poovamraj Hi, please let me know if I am missing any step for this to be reviewed 😄 |
Hi @JCQuintas, thanks for your contribution and apologies for the delay. I'll try to get to this PR by EOW. |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #393 +/- ##
=============================================
- Coverage 96.08% 82.89% -13.20%
=============================================
Files 97 108 +11
Lines 1611 1877 +266
Branches 331 424 +93
=============================================
+ Hits 1548 1556 +8
- Misses 49 308 +259
+ Partials 14 13 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@JCQuintas @Widcket Any updates on this? The |
cc @pmathew92 |
Hi all, apologies on the delayed response. We will review this and plan to include this PR in our coming releases. @JCQuintas could you please resolve the merge conflicts ? |
Hi @pmathew92, I don't work with Flutter anymore so it would be hard for me to validate the changes, anyone interested can take over this PR. |
📋 Changes
openUrl
parameter in bothloginWithRedirect
andlogout
on the browser version.openUrl
requires auth0-spa-js version2.0.1
or later.This is important to me due to the @microsoft/teams-js library necessary to do authentication inside microsoft teams, reference docs here
In short, it handles authentication in its own window.
My use case would be something similar to
🎯 Testing
2.0
to2.0.1
atauth0_flutter/example/web/index.html
loginWithRedirect
andlogout
functionsPossible concerns
While manual testing, you will also see two errors in the web console:
Error: Promise was rejected with a value of 'undefined'
TypeError: T.as is not a function
From my tests, this seems be comming out of the main
auth0-spa-js
library due to unhandled rejections, and doesn't affect the usage ofauth0_flutter
itself. Though it would require a deeper research on why it is happening.