mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Address code review: fix comment
This commit is contained in:
@@ -54,7 +54,7 @@ tests/cases/conformance/jsx/file.tsx(35,8): error TS2322: Type '{ x: string; y:
|
||||
!!! error TS2322: Types of property 'x' are incompatible.
|
||||
!!! error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
|
||||
// OK
|
||||
// Error
|
||||
var obj6 = { x: 'ok', y: 32, extra: 100 };
|
||||
<test1 {...obj6} />
|
||||
~~~~~~~~~
|
||||
|
||||
@@ -31,7 +31,7 @@ var obj4 = { x: 32, y: 32 };
|
||||
var obj5 = { x: 32, y: 32 };
|
||||
<test1 x="ok" {...obj5} />
|
||||
|
||||
// OK
|
||||
// Error
|
||||
var obj6 = { x: 'ok', y: 32, extra: 100 };
|
||||
<test1 {...obj6} />
|
||||
|
||||
@@ -56,7 +56,7 @@ var obj4 = { x: 32, y: 32 };
|
||||
// Error
|
||||
var obj5 = { x: 32, y: 32 };
|
||||
<test1 x="ok" {...obj5}/>;
|
||||
// OK
|
||||
// Error
|
||||
var obj6 = { x: 'ok', y: 32, extra: 100 };
|
||||
<test1 {...obj6}/>;
|
||||
// OK (spread override)
|
||||
|
||||
@@ -32,7 +32,7 @@ var obj4 = { x: 32, y: 32 };
|
||||
var obj5 = { x: 32, y: 32 };
|
||||
<test1 x="ok" {...obj5} />
|
||||
|
||||
// OK
|
||||
// Error
|
||||
var obj6 = { x: 'ok', y: 32, extra: 100 };
|
||||
<test1 {...obj6} />
|
||||
|
||||
|
||||
Reference in New Issue
Block a user