Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Missing static native methods from dart:html #36205
Some (maybe all) static native methods in dart:html are not available when you build with DDC but they are when you build with dart2js.
It looks like I spotted this bug (I wasn't the original code author) from reading it and left a helpful TODO:
// A static native element should just forward directly to the // JS type's member. // // TODO(jmesserly): this code path seems broken. It doesn't exist // elsewhere, such as [_emitAccess], so it will only take affect for // unqualified static access inside of the the same class. // // If we want this feature to work, we'll need to implement it in the // standard [_emitStaticClassName] code path, which will need to know the // member we're calling so it can determine whether to use the Dart class // name or the native JS class name.
It looks like I fixed it in the DDC+Kernel backend, so it only affects DDC+Analyzer.