// @filename: file.tsx // @jsx: preserve // @noLib: true // @skipLibCheck: true // @libFiles: react.d.ts,lib.d.ts import React = require('react'); interface PoisonedProp { x: string; y: 2; } class Poisoned extends React.Component { render() { return
Hello
; } } let obj = { x: "hello world", y: 2 }; // Error as "obj" has type { x: string; y: number } let p = ; class EmptyProp extends React.Component<{}, {}> { render() { return
Default hi
; } greeting: string; } let o = { prop1: false } // Ok let e = ;