Trying to call a javascript method that required a typed array.
var arrayData = js.array(new Uint8Array.fromList(data.charCodes));
Using js.array does not proxy it the way I was expecting, how could I pass the typed array as a typed array to a javascript method in dart?
You can instantiate
ArrayBufferandUint8Arrayjavascript objects directly from Dart.If you need only a
Uint8Arrayjavascript object :If you need an
ArrayBufferjavascript object:Basically, each time you need to use the
newjavascript operator, you have to usenew js.Proxy(construtor,...).WARNING : Until a new version has landed containing the pull-request #34 of js-interop, you have to use the following dependency to run the above code snippet.