# react-children-render

> A component for rendering children.

Latest version **1.0.2** (published 2017-09-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-children-render
pnpm add react-children-render
yarn add react-children-render
bun add react-children-render
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2017-09-27 |
| First published | 2017-09-03 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Romello Goodman |
| Maintainers | romellogood |
| Keywords | react |

## Links

- npm: https://www.npmjs.com/package/react-children-render
- Repository: https://github.com/romellogood/react-children-render
- Homepage: https://github.com/romellogood/react-children-render#readme
- Issues: https://github.com/romellogood/react-children-render/issues
- npm.io page: https://npm.io/package/react-children-render

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.2 (latest) — 2017-09-27
- 1.0.1 — 2017-09-03

## README

# react-children-render
A component for rendering children.

[![npm](https://img.shields.io/npm/v/react-children-render.svg)](https://www.npmjs.com/package/react-children-render)

## Usage

```js
import React from 'react';
import Children from 'react-children-render';

const Component = () => {
  return (
    <Children>
      <p>Foo</p>
      <p>Bar</p>
    </Children>
  );
};
```

```html
<!-- HTML Output -->
<p>Foo</p>
<p>Bar</p>
```

## Why?

Before React v16, returning adjacent JSX elements had to be wrapped in an enclosing tag.

```js
import React from 'react';

const Component = () => {
  return (
    <div>
      <p>Foo</p>
      <p>Bar</p>
    </div>
  );
};
```

After React v16, a single component can return multiple components without an enclosing tag.

```js
import React from 'react';

const Component = () => {
  return [
    <p key='1'>Foo</p>
    <p key='2'>Bar</p>
  ];
};
```

With react-children-render you can eliminate the need for unique keys.

---
_Source: https://npm.io/package/react-children-render · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
