Skip to content

Commit

Permalink
Update Fragment imports in READMEs (#15262)
Browse files Browse the repository at this point in the history
Some Fragment imports were incorrect. Fix them.
  • Loading branch information
sirreal authored and gziolo committed Apr 30, 2019
1 parent 297c2f4 commit c1ba13e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/block-editor/src/components/url-popover/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ URLPopover is a presentational React component used to render a popover used for
The component will be rendered adjacent to its parent.

```jsx
import { Fragment } from '@wordpress/elements';
import { Fragment } from '@wordpress/element';
import { ToggleControl, IconButton, Button } from '@wordpress/components';
import { URLPopover } from '@wordpress/block-editor';

Expand Down
6 changes: 4 additions & 2 deletions packages/components/src/higher-order/with-filters/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ Wrapping a component with `withFilters` provides a filtering capability controll
## Usage

```jsx
import { Fragment, withFilters } from '@wordpress/components';
import { Fragment } from '@wordpress/element';
import { withFilters } from '@wordpress/components';
import { addFilter } from '@wordpress/hooks';

const MyComponent = ( { title } ) => <h1>{ title }</h1>;
Expand Down Expand Up @@ -37,7 +38,8 @@ const MyComponentWithFilters = withFilters( 'MyHookName' )( MyComponent );
It is also possible to override props by implementing a higher-order component which works as follows:

```jsx
import { Fragment, withFilters } from '@wordpress/components';
import { Fragment } from '@wordpress/element';
import { withFilters } from '@wordpress/components';
import { addFilter } from '@wordpress/hooks';

const MyComponent = ( { hint, title } ) => (
Expand Down

0 comments on commit c1ba13e

Please sign in to comment.