UNPKG

@wordpress/plugins

Version:
44 lines 954 B
import type { WPPlugin } from '../../api'; /** * A component that renders all plugin fills in a hidden div. * * @param props * @param props.scope * @param props.onError * @example * ```js * // Using ES5 syntax * var el = React.createElement; * var PluginArea = wp.plugins.PluginArea; * * function Layout() { * return el( * 'div', * { scope: 'my-page' }, * 'Content of the page', * PluginArea * ); * } * ``` * * @example * ```js * // Using ESNext syntax * import { PluginArea } from '@wordpress/plugins'; * * const Layout = () => ( * <div> * Content of the page * <PluginArea scope="my-page" /> * </div> * ); * ``` * * @return {Component} The component to be rendered. */ declare function PluginArea({ scope, onError, }: { scope?: string; onError?: (name: WPPlugin['name'], error: Error) => void; }): import("react").JSX.Element; export default PluginArea; //# sourceMappingURL=index.d.ts.map