auth0 / auth0-flutter

Auth0 SDK for Flutter
https://pub.dev/documentation/auth0_flutter/latest/
Apache License 2.0
57 stars 37 forks source link

Add support for passing parameters onLoad #363

Closed frederikprijck closed 7 months ago

frederikprijck commented 7 months ago

πŸ“‹ Changes

Adds support for passing custom parameters to onLoad, which are used as global custom parameters in the underlying Auth0-SPA-JS SDK.

πŸ“Ž References

Closes #345

🎯 Testing

Update the sample application here:

auth0Web.onLoad(parameters: {'foo': 'bar'}).then((final credentials) => setState(() {
  _output = credentials?.idToken ?? '';
  _isLoggedIn = credentials != null;
}));
codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (253209a) 96.08% compared to head (cc8b662) 96.31%. Report is 29 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #363 +/- ## ============================================ + Coverage 96.08% 96.31% +0.22% ============================================ Files 97 98 +1 Lines 1611 1573 -38 Branches 331 328 -3 ============================================ - Hits 1548 1515 -33 - Misses 49 50 +1 + Partials 14 8 -6 ``` | [Flag](https://app.codecov.io/gh/auth0/auth0-flutter/pull/363/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0) | Coverage Ξ” | | |---|---|---| | [auth0_flutter](https://app.codecov.io/gh/auth0/auth0-flutter/pull/363/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0) | `100.00% <100.00%> (ΓΈ)` | | | [auth0_flutter_android](https://app.codecov.io/gh/auth0/auth0-flutter/pull/363/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0) | `97.35% <ΓΈ> (+0.79%)` | :arrow_up: | | [auth0_flutter_ios](https://app.codecov.io/gh/auth0/auth0-flutter/pull/363/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0) | `99.84% <ΓΈ> (ΓΈ)` | | | [auth0_flutter_platform_interface](https://app.codecov.io/gh/auth0/auth0-flutter/pull/363/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0) | `87.03% <100.00%> (ΓΈ)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=auth0#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

frederikprijck commented 7 months ago

Needs https://github.com/auth0/auth0-flutter/pull/364 to fix the CI.