You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Avoid using js_util.promiseToFuture, instead prefer the extension on JSPromise<> #143396
The flutter web engine should avoid using js_util.promiseToFuture (which operates on Dart types and therefore requires dartify() behavior) and instead use static interop via the extension on JSPromise, see JSPromiseToFuture.toDart
Removing labels to trigger a re-triage, we should do this. As Srujan says, we should actually remove all usages of dart:js_util and migrate to dart:js_interop. This seems to include the definition of the kIsWeb constant (which to me is the scariest part of the change :))
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.
Activity
srujzs commentedon Feb 13, 2024
In general, if we can migrate off of
dart:js_util, we can remove Flutter from the allowlist here: https://github.com/dart-lang/sdk/blob/1c5eccdd2b258be67251719ed87595d21614545f/pkg/_js_interop_checks/lib/js_interop_checks.dart#L109. We could probably also remove the implementations ofpromiseToFutureandallowInteropat that time because I believe no one else is using them.ditman commentedon Jan 7, 2025
Removing labels to trigger a re-triage, we should do this. As Srujan says, we should actually remove all usages of
dart:js_utiland migrate todart:js_interop. This seems to include the definition of thekIsWebconstant (which to me is the scariest part of the change :))[web] Remove all usages of js_util. (#171871)
[web] Remove all usages of js_util. (flutter#171871)
github-actions commentedon Jul 30, 2025
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.[web] Remove all usages of js_util. (flutter#171871)
[web] Remove all usages of js_util. (flutter#171871)
[web] Remove all usages of js_util. (flutter#171871)
[web] Remove all usages of js_util. (#171871)