Intersects a type that has a status string field with boolean helpers of the form is{Status} for every status value in the union.
status
is{Status}
Snake_case status values are converted to camelCase: 'not_connected' → isNotConnected
'not_connected'
isNotConnected
type MyResult = WithStatusBooleans< | { status: 'success'; data: string } | { status: 'not_found' }>// Result has: isSuccess, isNotFound Copy
type MyResult = WithStatusBooleans< | { status: 'success'; data: string } | { status: 'not_found' }>// Result has: isSuccess, isNotFound
Intersects a type that has a
statusstring field with boolean helpers of the formis{Status}for every status value in the union.Snake_case status values are converted to camelCase:
'not_connected'→isNotConnected