<Group>

Inserts separators between its children.

Usage

Import:

import {Group} from 'libreact/lib/Group';

Default separator is a space " ".

<Group>
  <span>Hello</span>
  <span>world</span>
</Group>

Result:

<div>
  <span>Hello</span> <span>world</span>
</div>

Use custom separator.

<Group separator={<hr />}>
  <span>Hello</span>
  <span>world</span>
</Group>

Use as prop to specify wrapper element tag name.

<Group as="span">
  <span>Hello</span>
  <span>world</span>
</Group>

Pass through any props to the wrapper element.

<Group className="foobar">
  <span>Hello</span>
  <span>world</span>
</Group>

results matching ""

    No results matching ""