mirror: A fast canonicalisation utility for stable object equality
0

Configure Feed

Select the types of activity you want to include in your feed.

chore: create type tests

Marais Rossouw (Jun 28, 2023, 5:43 PM +1000) e12a38fa ae4ec49f

+9
+9
src/index.types.ts
··· 1 + import { identify } from 'object-identity'; 2 + 3 + declare function assert<T>(thing: T): void; 4 + 5 + assert<string>(identify('string')); 6 + assert<string>(identify(1)); 7 + assert<string>(identify([])); 8 + assert<string>(identify({})); 9 + assert<string>(identify(new Error()));