|
1 | 1 | tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx(20,46): error TS2322: Type '"y"' is not assignable to type '"x"'.
|
2 |
| -tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx(21,19): error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x" | "y">'. |
3 |
| - Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'LitProps<"x" | "y">'. |
| 2 | +tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx(21,19): error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x">'. |
| 3 | + Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'LitProps<"x">'. |
4 | 4 | Types of property 'children' are incompatible.
|
5 |
| - Type '(p: LitProps<"x">) => "y"' is not assignable to type '(x: LitProps<"x" | "y">) => "x" | "y"'. |
6 |
| - Types of parameters 'p' and 'x' are incompatible. |
7 |
| - Type 'LitProps<"x" | "y">' is not assignable to type 'LitProps<"x">'. |
8 |
| - Types of property 'prop' are incompatible. |
9 |
| - Type '"x" | "y"' is not assignable to type '"x"'. |
10 |
| - Type '"y"' is not assignable to type '"x"'. |
| 5 | + Type '(p: LitProps<"x">) => "y"' is not assignable to type '(x: LitProps<"x">) => "x"'. |
| 6 | + Type '"y"' is not assignable to type '"x"'. |
11 | 7 | tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx(22,21): error TS2322: Type '{ children: () => number; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x">'.
|
12 | 8 | Type '{ children: () => number; prop: "x"; }' is not assignable to type 'LitProps<"x">'.
|
13 | 9 | Types of property 'children' are incompatible.
|
@@ -41,15 +37,11 @@ tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx(22,21): error TS2322:
|
41 | 37 | !!! related TS6502 tests/cases/compiler/jsxChildrenGenericContextualTypes.tsx:13:44: The expected type comes from the return type of this signature.
|
42 | 38 | const argchild = <ElemLit prop="x">{p => "y"}</ElemLit>
|
43 | 39 | ~~~~~~~
|
44 |
| -!!! error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x" | "y">'. |
45 |
| -!!! error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'LitProps<"x" | "y">'. |
| 40 | +!!! error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x">'. |
| 41 | +!!! error TS2322: Type '{ children: (p: LitProps<"x">) => "y"; prop: "x"; }' is not assignable to type 'LitProps<"x">'. |
46 | 42 | !!! error TS2322: Types of property 'children' are incompatible.
|
47 |
| -!!! error TS2322: Type '(p: LitProps<"x">) => "y"' is not assignable to type '(x: LitProps<"x" | "y">) => "x" | "y"'. |
48 |
| -!!! error TS2322: Types of parameters 'p' and 'x' are incompatible. |
49 |
| -!!! error TS2322: Type 'LitProps<"x" | "y">' is not assignable to type 'LitProps<"x">'. |
50 |
| -!!! error TS2322: Types of property 'prop' are incompatible. |
51 |
| -!!! error TS2322: Type '"x" | "y"' is not assignable to type '"x"'. |
52 |
| -!!! error TS2322: Type '"y"' is not assignable to type '"x"'. |
| 43 | +!!! error TS2322: Type '(p: LitProps<"x">) => "y"' is not assignable to type '(x: LitProps<"x">) => "x"'. |
| 44 | +!!! error TS2322: Type '"y"' is not assignable to type '"x"'. |
53 | 45 | const mismatched = <ElemLit prop="x">{() => 12}</ElemLit>
|
54 | 46 | ~~~~~~~
|
55 | 47 | !!! error TS2322: Type '{ children: () => number; prop: "x"; }' is not assignable to type 'IntrinsicAttributes & LitProps<"x">'.
|
|
0 commit comments