UNPKG

@seasketch/geoprocessing

Version:

Geoprocessing and reporting framework for SeaSketch 2.0

8 lines (7 loc) 422 B
/** * Type narrowing to allow property checking when object can be multiple types * https://fettblog.eu/typescript-hasownproperty/ * Any code inside a block guarded by a conditional call to this function will have type narrowed to X */ export declare function hasOwnProperty<X extends {}, Y extends PropertyKey>(obj: X, prop: Y): obj is X & Record<Y, unknown>; export declare function isObject(val: unknown): boolean;