ObjectValue<T>
type ObjectValue\<T\> = T[keyof T];
Defined in: src/lib/utils.ts:20
A utility type to extract the values of an object.
Type Parameters
| Type Parameter |
|---|
T |
Example
const obj = {
a: 1,
b: 2,
} as const;
type ObjValues = ObjectValue<typeof obj>;
// type ObjValues = 1 | 2