mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-16 23:10:29 +00:00
Prefer to directly export values instead of export = of a namespace (#13645)
This commit is contained in:
Vendored
+14
-17
@@ -4,21 +4,18 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
import { ReactElement } from "react";
|
||||
declare namespace ReactTestRenderer {
|
||||
export interface Renderer {
|
||||
toJSON(): ReactTestRendererJSON;
|
||||
}
|
||||
export interface ReactTestRendererJSON {
|
||||
type: string;
|
||||
props: { [propName: string]: string };
|
||||
children: null | Array<string | ReactTestRendererJSON>;
|
||||
$$typeof?: any;
|
||||
}
|
||||
export interface TestRendererOptions {
|
||||
createNodeMock: (element: ReactElement<any>) => any;
|
||||
}
|
||||
// https://github.com/facebook/react/blob/master/src/renderers/testing/ReactTestMount.js#L155
|
||||
export function create(nextElement: ReactElement<any>, options?: TestRendererOptions): Renderer;
|
||||
}
|
||||
|
||||
export = ReactTestRenderer;
|
||||
interface Renderer {
|
||||
toJSON(): ReactTestRendererJSON;
|
||||
}
|
||||
interface ReactTestRendererJSON {
|
||||
type: string;
|
||||
props: { [propName: string]: string };
|
||||
children: null | Array<string | ReactTestRendererJSON>;
|
||||
$$typeof?: any;
|
||||
}
|
||||
interface TestRendererOptions {
|
||||
createNodeMock: (element: ReactElement<any>) => any;
|
||||
}
|
||||
// https://github.com/facebook/react/blob/master/src/renderers/testing/ReactTestMount.js#L155
|
||||
export function create(nextElement: ReactElement<any>, options?: TestRendererOptions): Renderer;
|
||||
|
||||
Reference in New Issue
Block a user