Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit d6bebcd

Browse files
authored
docs: warn about missing fragments support in <16 (#156)
React 15 and lower, and Preact, don't support components that return fragments. Added a warning in the documentation to help these users.
1 parent 8633eeb commit d6bebcd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ const Example = () => (
5858
`react-popper` makes use of a React pattern called **"render prop"**, if you are not
5959
familiar with it, please read more [on the official React documentation](https://reactjs.org/docs/render-props.html).
6060

61+
> Using React <=15 or Preact? The components created with them don't support to return
62+
[fragments](https://reactjs.org/docs/fragments.html), this means that you will need to
63+
wrap `<Reference />` and `<Popper />` into a `<div />` to make `react-popper` work.
64+
6165
### API documentation
6266

6367
The `Manager` component is a simple wrapper that needs to surround all the other `react-popper` components in order

0 commit comments

Comments
 (0)