Skip to content

Commit

Permalink
Narrow the return type
Browse files Browse the repository at this point in the history
  • Loading branch information
sarayourfriend committed May 21, 2021
1 parent 510209d commit cbdcf12
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/compose/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ _Parameters_

_Returns_

- `import('react').Ref<TypeFromRef<T>>`: The merged ref callback.
- `import('react').RefCallback<TypeFromRef<T>>`: The merged ref callback.

<a name="usePrevious" href="#usePrevious">#</a> **usePrevious**

Expand Down
2 changes: 1 addition & 1 deletion packages/compose/src/hooks/use-merge-refs/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ function assignRef( ref, value ) {
* @template {import('react').Ref<any>} T
* @param {Array<T>} refs The refs to be merged.
*
* @return {import('react').Ref<TypeFromRef<T>>} The merged ref callback.
* @return {import('react').RefCallback<TypeFromRef<T>>} The merged ref callback.
*/
export default function useMergeRefs( refs ) {
const element = useRef();
Expand Down

0 comments on commit cbdcf12

Please sign in to comment.