node's buffer module, but for the browser.