docs: function toUint8Array(object) {
      if (object instanceof Uint8Array) return object;
      if (Array.isArray(object)) return new Uint8Array(object);
      if (('byteOffset' in object) && ('byteLength' in object)) {
        var array = new Array(object.byteLength);
        for (var i = 0; i < object.byteLength; i++) {
          array[i] = object[i + object.byteOffset];
        }
        return new Uint8Array(array);
      }
      throw new Error("Unable to create Uint8Array");
    }