* Actually get the apparent type of intersection members when calculating intersection apparent types * Add nonjsx variant * Fix nit
17 lines
336 B
TypeScript
17 lines
336 B
TypeScript
// @strictNullChecks: true
|
|
// @noImplicitAny: true
|
|
interface Component<P> {
|
|
props: Readonly<P> & Readonly<{ children?: {} }>;
|
|
}
|
|
|
|
interface Props {
|
|
children?: (items: {x: number}) => void
|
|
}
|
|
|
|
declare function f<T extends Props>(i: Component<T>): void;
|
|
|
|
f({
|
|
props: {
|
|
children: (({ x }) => { })
|
|
}
|
|
}); |