-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
area-web-jsIssues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.web-js-interopIssues that impact all js interopIssues that impact all js interop
Description
// There are also JS typed arguments and fields, used on the JS side, that accept null values.
extension type AppProperties._(JSObject _) implements JSObject {
// So, I can't use checks like this
factory AppProperties({void Function(({String text}))? message, int? optional}) {
if (optional == null) {
return AppProperties.__(message?.toExternalReference);
}
return AppProperties.__(message?.toExternalReference, optional: optional.toJS);
}
// No type check, can pass reference to anything.
external factory AppProperties({ExternalDartReference? message});
@JS('message')
external ExternalDartReference? _message;
void Function(({String text}))? get message {
return _message?.toDartObject as void Function(({String text}))?;
}
}Metadata
Metadata
Assignees
Labels
area-web-jsIssues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.web-js-interopIssues that impact all js interopIssues that impact all js interop
Type
Projects
Status
Done