You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get this typescript error when exactOptionalPropertyTypes is true in my tsconfig
Argument of type '{ encode: (value: string[]) => string; decode: (value: string | null) => string[] | null; defaultValue: string[] | undefined; }' is not assignable to parameter of type 'EncodeAndDecodeOptions<string[]>' with 'exactOptionalPropertyTypes: true'. Consider adding 'undefined' to the types of the target's properties.
Types of property 'defaultValue' are incompatible.
Type 'string[] | undefined' is not assignable to type 'string[]'.
Type 'undefined' is not assignable to type 'string[]'.ts(2379)
Describe the bug
Given this code:
const booleanFilters = queryParam('bf', ssp.array<string>([]));
I get this typescript error when
exactOptionalPropertyTypes
is true in my tsconfigReproduction
Logs
No response
The text was updated successfully, but these errors were encountered: