1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
|
=== tests/cases/conformance/jsx/file.tsx ===
import React = require('react');
>React : Symbol(React, Decl(file.tsx, 0, 0))
function SFC1(prop: { x: number }) {
>SFC1 : Symbol(SFC1, Decl(file.tsx, 0, 32))
>prop : Symbol(prop, Decl(file.tsx, 2, 14))
>x : Symbol(x, Decl(file.tsx, 2, 21))
return <div>hello</div>;
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
};
function SFC2(prop: { x: boolean }) {
>SFC2 : Symbol(SFC2, Decl(file.tsx, 4, 2))
>prop : Symbol(prop, Decl(file.tsx, 6, 14))
>x : Symbol(x, Decl(file.tsx, 6, 21))
return <h1>World </h1>;
>h1 : Symbol(JSX.IntrinsicElements.h1, Decl(react.d.ts, 2410, 47))
>h1 : Symbol(JSX.IntrinsicElements.h1, Decl(react.d.ts, 2410, 47))
}
var SFCComp = SFC1 || SFC2;
>SFCComp : Symbol(SFCComp, Decl(file.tsx, 10, 3))
>SFC1 : Symbol(SFC1, Decl(file.tsx, 0, 32))
>SFC2 : Symbol(SFC2, Decl(file.tsx, 4, 2))
<SFCComp x={"hi"}/>
>SFCComp : Symbol(SFCComp, Decl(file.tsx, 10, 3))
>x : Symbol(x, Decl(file.tsx, 11, 8))
|