UNPKG

871 BTypeScriptView Raw
1import { ComponentClass } from 'react';
2declare const experimental: (...args: unknown[]) => (ComposedComponent: ComponentClass<any, any>) => any;
3export default experimental;
4export {
5/**
6 * ---
7 * category: utilities/react
8 * ---
9 * Flag React component and component props as experimental.
10 * Warnings will display in the console when experimental components/props
11 * props are used.
12 *
13 * ```js
14 * class Example extends Component {
15 * static propTypes = {
16 * currentProp: PropTypes.func
17 * }
18 * }
19 * export default experimental(['experimentalProp'])(Example)
20 * ```
21 *
22 * @module experimental
23 * @param {array} experimentalProps (if this argument is null or undefined, the entire component is flagged)
24 * @param {string} message
25 * @return {function} React component flagged as experimental
26 */
27experimental };
28//# sourceMappingURL=experimental.d.ts.map
\No newline at end of file