UNPKG

@thi.ng/ksuid

Version:

Configurable K-sortable unique IDs, ULIDs, binary & base-N encoded, 32/48/64bit time resolutions

18 lines 583 B
import { AKSUID } from "./aksuid.js"; import type { KSUIDOpts } from "./api.js"; export declare class KSUID32 extends AKSUID { constructor(opts?: Partial<KSUIDOpts>); timeOnlyBinary(epoch?: number, buf?: Uint8Array): Uint8Array<ArrayBufferLike>; parse(id: string): { epoch: number; id: Uint8Array<ArrayBuffer>; }; } /** * Creates and returns a new 32bit epoch KSUID generator instance (w/ second * time precision). * * @param opts - */ export declare const defKSUID32: (opts?: Partial<KSUIDOpts>) => KSUID32; //# sourceMappingURL=ksuid32.d.ts.map