description

# toDart property

ByteBuffer get toDart

Converts this JSArrayBuffer to a ByteBuffer by either casting or wrapping it.

Note

Depending on whether code is compiled to JavaScript or Wasm, this conversion will have different semantics.

When compiling to JavaScript, ByteBuffers are JSArrayBuffers and this operation will be a cast.

When compiling to Wasm, the JSArrayBuffer is wrapped with a ByteBuffer implementation and the wrapper is returned.

Modifications to this JSArrayBuffer will affect the returned ByteBuffer and vice versa.

## Implementation

    external ByteBuffer get toDart;