Omit<T, K>

The utility type that copies type T without the listed keys K, like a denylist of fields.

In more detail

Omit<UserEntity, "id" | "createdAt"> is the shape a client sends when creating a user. Use it when you want everything except a few server-managed fields.

Related terms

Taught in

References