Open
Description
π Search Terms
array intersection spread any
π Version & Regression Information
- This is the behavior in every version I tried
β― Playground Link
π» Code
type withExtraProps = extractArray<{ name: string } & string[]>;
// ^? any[]
type extractArray<t extends readonly unknown[]> = [...{ [i in keyof t]: t[i] }];
π Actual behavior
Inferred as any[]
due to an internal error type
π Expected behavior
Inferred as string[]