Open ghost opened 5 years ago
@terrylucas
Here's the example.
import 'dart:html';
void main() async {
await window.navigator.mediaDevices.enumerateDevices();
}
Any update on this? This is pretty frustrating that a basic API method just doesn't work. :(
This is reproducible on DartPad, which is currently running Dart SDK 2.1.0. Error message is "TypeError: Instance of 'JSArray': type 'JSArray' is not a subtype of type 'FutureOr<List>'".
This is on Chrome 70.0.3538.110 on OSX 10.14.1
See https://dartpad.dartlang.org/d2c410232a233d2c57605dc3583a52f5 for an example. Running this script results in an error in the Chrome developer console, and no error in the DartPad results console.