mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-10-23 06:10:02 +08:00
Represent ordinary JavaScript arrays with hole, value, and explicit-undefined states; add sparse side storage and carry missing values through the frontend, native backends, runtime, and Node-facing consumers.
9 lines
148 B
TypeScript
9 lines
148 B
TypeScript
const parts: Uint8Array[] = [];
|
|
parts[1] = Buffer.from("b");
|
|
|
|
try {
|
|
Buffer.concat(parts);
|
|
} catch {
|
|
console.log("caught sparse concat item");
|
|
}
|