These two operators let you derive types from existing types and values — the foundation of type-level programming.
keyof — the union of an object type's keys
ts
interface User { id: number; name: string; }
type UserKey = keyof User; // "id" | "name"
typeof — the type of a value
ts
config = { : , : };
= config;
