Skip to content

React Utils - v2.1.0

Choose a tag to compare

@ItsJonQ ItsJonQ released this 28 Feb 15:26
· 13 commits to master since this release

Add Fragment

This update adds a simple React.Fragment "polyfill" for React.Fragment.

It will render a native React.Fragment if supported. Otherwise, it will
wrap the children within a selector. Default is div.

Props

Props Type Description
selector string A selector to render. Default div.

Returns

React.Component: A "Fragment" wrapped React component

Examples

import Fragment from '@helpscout/react-utils/dist/Fragment'

const Pedro = () => (
  <Fragment>
    <Napoleon />
    <Debra />
  </Fragment>
)

Zero updates

This update also bumps @helpscout/zero to the latest version, allowing us to remove np and husky as dependencies.


v2.0.1...v2.1.0