-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Expanded type guard suggestions #4868
Copy link
Copy link
Closed
Labels
Effort: DifficultGood luck.Good luck.FixedA PR has been merged for this issueA PR has been merged for this issueHelp WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Metadata
Metadata
Assignees
Labels
Effort: DifficultGood luck.Good luck.FixedA PR has been merged for this issueA PR has been merged for this issueHelp WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript
Type
Fields
Give feedbackNo fields configured for issues without a type.
Potential "safe" type guards based on in-office discussion:
typeof x === 'function', remove any types from the union that do not have call or construct signaturestypeof x === 'object', remove all primitives from the union, as well as any types that have any call or construct signatures