Module

x/typebox/src/value/guard/guard.ts>HasPropertyKey

Json Schema Type Builder with Static Type Resolution for TypeScript
Go to Latest
function HasPropertyKey
import { HasPropertyKey } from "https://dotland.deno.dev/x/typebox@0.33.22/src/value/guard/guard.ts";

Returns true if this value has this property key

Type Parameters

K extends PropertyKey

Parameters

value: Record<any, unknown>
key: K

Returns

value is Record<PropertyKey, unknown> & [_ in K]: unknown