f798a8bca4
override some of its imports as they would just add a lot of nodejs fluff that needs stubbing out for a browser.
6 lines
263 B
JavaScript
6 lines
263 B
JavaScript
module.exports = class Buffer {
|
|
static isBuffer(array) {return array instanceof Uint8Array;}
|
|
static from(arrayBuffer) {return arrayBuffer;}
|
|
static allocUnsafe(size) {return Buffer.alloc(size);}
|
|
static alloc(size) {return new Uint8Array(size);}
|
|
};
|