UNPKG

ts-mdls

Version:

Lightweigth, dependency free, fully typed wrapper of the macOS `mdls` command

10 lines (8 loc) 183 B
export class IsNotNullError extends Error {} export default function parseNull(s: string) { if (s === "(null)") { return null; } else { throw new IsNotNullError(); } }