// @jsx: react declare module JSX { interface Element { } interface IntrinsicElements { [s: string]: any; } } declare var React: any; interface TodoProp { id: number; todo: string; } interface TodoListProps { todos: TodoProp[]; } function Todo(prop: { key: number, todo: string }) { return
{prop.key.toString() + prop.todo}
; } function TodoList({ todos }: TodoListProps) { return
{...}
; } function TodoListNoError({ todos }: TodoListProps) { // any is not checked return
{...( as any)}
; } let x: TodoListProps;