UNPKG

@atcute/car

Version:

lightweight DASL CAR and atproto repository decoder for AT Protocol.

10 lines 385 B
import * as CBOR from '@atcute/cbor'; import * as CID from '@atcute/cid'; export const isCarV1Header = (value) => { if (value === null || typeof value !== 'object') { return false; } const { version, roots } = value; return version === 1 && Array.isArray(roots) && roots.every((root) => root instanceof CBOR.CidLinkWrapper); }; //# sourceMappingURL=types.js.map