From d4f4a7a77684688b32ef3744d9fe902e2c3206af Mon Sep 17 00:00:00 2001 From: Rimuy <46044567+Rimuy@users.noreply.github.com> Date: Fri, 9 Jul 2021 20:25:22 -0300 Subject: [PATCH] Fix Roact.forwardRef description (#312) Fixes the Roact.forwardRef description which is currentlyRoact.createRef instead. --- CHANGELOG.md | 1 + docs/api-reference.md | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6cb521ad..9eac0588 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # Roact Changelog ## Unreleased Changes +* Fixed forwardRef description ([#312](https://github.com/Roblox/roact/pull/312)). ## [1.4.0](https://github.com/Roblox/roact/releases/tag/v1.4.0) (November 19th, 2020) * Introduce forwardRef ([#307](https://github.com/Roblox/roact/pull/307)). diff --git a/docs/api-reference.md b/docs/api-reference.md index 35091e47..ff551409 100644 --- a/docs/api-reference.md +++ b/docs/api-reference.md @@ -184,7 +184,7 @@ Creates a new reference object that can be used with [Roact.Ref](#roactref). !!! success "Added in Roact 1.4.0" ``` -Roact.createRef(render: (props: table, ref: Ref) -> RoactElement) -> RoactComponent +Roact.forwardRef(render: (props: table, ref: Ref) -> RoactElement) -> RoactComponent ``` Creates a new component given a render function that accepts both props and a ref, allowing a ref to be forwarded to an underlying host component via [Roact.Ref](#roactref).