From 89bf0592e3f4f7e4a491c378bdf5692b4fe89582 Mon Sep 17 00:00:00 2001 From: Nissim Scialom <39900426+nissimscialom@users.noreply.github.com> Date: Fri, 30 Dec 2022 05:32:54 +0200 Subject: [PATCH] docs - added children props to custom child component example (#1817) --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 44478b093..0c23a0764 100644 --- a/README.md +++ b/README.md @@ -556,10 +556,11 @@ If you use React Components as grid children, they need to do a few things: For example: ```js -const CustomGridItemComponent = React.forwardRef(({style, className, onMouseDown, onMouseUp, onTouchEnd, ...props}, ref) => { +const CustomGridItemComponent = React.forwardRef(({style, className, onMouseDown, onMouseUp, onTouchEnd, children, ...props}, ref) => { return (
{/* Some other content */} + {children} {/* Make sure to include children to add resizable handle */}
); }