-
Notifications
You must be signed in to change notification settings - Fork 33
fix(crypto): update conditional import for js interop library #915
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?
fix(crypto): update conditional import for js interop library #915
Conversation
Previous changes to this conditional import 686d021 and 61dca74 did not add unit tests so I didn't either. I could potentially add WASM to the Crypto test matrix via |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
|
||
import 'digest.dart'; | ||
import 'hash.dart'; | ||
// ignore: uri_does_not_exist |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Is this ignore really necessary?
|
||
- Run `dart format` with the new style. | ||
- Performance improvements. | ||
- Updated web conditional import to use `js_interop` to support WebAssembly |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Updated web conditional import to use `js_interop` to support WebAssembly | |
- Updated web conditional import to use `js_interop` to support WebAssembly. |
;)
PR HealthBreaking changes ✔️
This check can be disabled by tagging the PR with Changelog Entry ✔️
Changes to files need to be accounted for in their respective changelogs. This check can be disabled by tagging the PR with Coverage ✔️
This check for test coverage is informational (issues shown here will not fail the PR). This check can be disabled by tagging the PR with API leaks ✔️The following packages contain symbols visible in the public API, but not exported by the library. Export these symbols or remove them from your publicly visible API.
This check can be disabled by tagging the PR with License Headers ✔️
All source files should start with a license header. This check can be disabled by tagging the PR with |
For web builds only
sha512_slowsinks.dart
is supported andsha512_fastsinks.dart
is not supported. The conditional importing ofsha512_slowsinks.dart
usesdart:js
instead of the new js interop librarydart:js_interop
, which does not work for WebAssembly builds. This change aligns us with the recommended conditional import to differentiate between native and web.#913
Contribution guidelines:
dart format
.Many Dart repos have a weekly cadence for reviewing PRs - please allow for some latency before initial review feedback.
Note: The Dart team is trialing Gemini Code Assist. Don't take its comments as final Dart team feedback. Use the suggestions if they're helpful; otherwise, wait for a human reviewer.