export function isObj(v: unknown): v is Record { return !!v && typeof v === 'object' } export function hasProp( data: object, prop: K, ): data is Record { return prop in data } export function isStrArray(v: unknown): v is string[] { return Array.isArray(v) && v.every(item => typeof item === 'string') }