Skip to content
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

Add web platform boilerplate [SDK-3983] #197

Merged
merged 4 commits into from
Feb 15, 2023
Merged

Conversation

Widcket
Copy link
Contributor

@Widcket Widcket commented Feb 15, 2023

  • All new/changed/fixed functionality is covered by tests (or N/A)
  • I have added documentation for all new/changed functionality (or N/A)

📋 Changes

This PR adds the web platform interface to the auth0_flutter_platform_interface package, and the respective –empty– implementation to the app-facing auth0_flutter package. For non-web platforms, this implementation is no-op, whereas for the web it allows to call the actual JS interop methods. The existing mobile-related files in the app-facing package were moved under a new mobile directory.

An empty Auth0Web class was also added to auth0_flutter.dart (in the app-facing package).

📎 References

This follows the approach explored in https://github.com/auth0/auth0-flutter/tree/flutter-web/option-2.

🎯 Testing

This was tested manually by adding a small JS library to index.html and calling it from Dart code.

@Widcket Widcket requested a review from a team as a code owner February 15, 2023 02:52
@codecov
Copy link

codecov bot commented Feb 15, 2023

Codecov Report

Base: 98.72% // Head: 98.31% // Decreases project coverage by -0.42% ⚠️

Coverage data is based on head (8a315a2) compared to base (cd5effb).
Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff              @@
##               beta     #197      +/-   ##
============================================
- Coverage     98.72%   98.31%   -0.42%     
  Complexity       82       82              
============================================
  Files            78       79       +1     
  Lines          1417     1423       +6     
  Branches        313      313              
============================================
  Hits           1399     1399              
- Misses            6       12       +6     
  Partials         12       12              
Flag Coverage Δ
auth0_flutter 100.00% <ø> (ø)
auth0_flutter_android 96.60% <ø> (ø)
auth0_flutter_ios 100.00% <ø> (ø)
auth0_flutter_platform_interface 97.17% <0.00%> (-2.11%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
auth0_flutter/lib/auth0_flutter.dart 100.00% <ø> (ø)
...th0_flutter/lib/src/mobile/authentication_api.dart 100.00% <ø> (ø)
...h0_flutter/lib/src/mobile/credentials_manager.dart 100.00% <ø> (ø)
...th0_flutter/lib/src/mobile/web_authentication.dart 100.00% <ø> (ø)
..._interface/lib/src/auth0_flutter_web_platform.dart 0.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@Widcket Widcket merged commit 0ac3733 into beta Feb 15, 2023
@Widcket Widcket deleted the chore/web-boilerplate branch February 15, 2023 12:22
This was referenced Apr 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants