TypeScript/tests/baselines/reference/spreadIntersectionJsx.types
Nathan Shively-Sanders bef1f9e87f call isValidSpreadType in createJsxAttributesTypeFromAttributesProperty
Previously, it only check for object and any types. This was the old
check, so this change updates it to use isValidSpreadType.
2017-02-16 10:41:35 -08:00

25 lines
379 B
Plaintext

=== tests/cases/compiler/spreadIntersectionJsx.tsx ===
const React: any = null;
>React : any
>null : null
class A { a; }
>A : A
>a : any
class C { c; }
>C : C
>c : any
let intersected: A & C;
>intersected : A & C
>A : A
>C : C
let element = <div { ...intersected } />;
>element : any
><div { ...intersected } /> : any
>div : any
>intersected : A & C