readBundle
import { readBundle } from 'pixi-silk/i18n';
function readBundle(buffer: ArrayBuffer, warn?: (message: string) => void): BundleData;
Reads a .silk bundle without copying: every table is a typed-array view over buffer, and only
the string table is decoded. Throws SilkBundleError on a wrong magic, another major
version, a truncated buffer or a misaligned section. A newer minor version calls warn.
Parameters#
| Parameter | Type | Default value |
|---|---|---|
buffer | ArrayBuffer | undefined |
warn | (message: string) => void | console.warn |