-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Labels
FixedA PR has been merged for this issueA PR has been merged for this issueSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
As spread and rest types is taking time I usually have to copy these types in projects. They solve the primary use case for spread/rest types and works today. I think they should fit right in next to Pick and Partial.
And even when (if?) spread and rest types is merged these would still arguably have some value.
export type Diff<T extends string, U extends string> = ({[P in T]: P} &
{[P in U]: never} & {[x: string]: never})[T]
export type Omit<T, K extends keyof T> = Pick<T, Diff<keyof T, K>>kitsonk, Ghabriel, lbguilherme, NN---, sean-vieira and 18 more
Metadata
Metadata
Assignees
Labels
FixedA PR has been merged for this issueA PR has been merged for this issueSuggestionAn idea for TypeScriptAn idea for TypeScript