From 7d776d72a41266dfbb77a0ffbacf99268e9b22a0 Mon Sep 17 00:00:00 2001 From: David Sancho Moreno Date: Wed, 20 Nov 2024 14:32:40 +0100 Subject: [PATCH] Use React.element in clone-element --- docs/clone-element.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/clone-element.md b/docs/clone-element.md index d75fc5f6a..a32f7a5b4 100644 --- a/docs/clone-element.md +++ b/docs/clone-element.md @@ -2,7 +2,7 @@ title: cloneElement --- -Signature: `let cloneElement: (reactElement, ~props: Js.t({..})=?, 'anyChildrenType) => reactElement` +Signature: `let cloneElement: (React.element, ~props: Js.t({..})=?, 'anyChildrenType) => React.element` Same as ReactJS' [cloneElement](https://reactjs.org/docs/react-api.html#cloneelement). However, adding extra props to a ReasonReact component doesn't make sense; you'd use a [**render prop**](https://reactjs.org/docs/render-props.html). Therefore, `ReasonReact.cloneElement` is only used in edge-cases.