Skip to content

Commit

Permalink
Change Ref to ForwardedRef
Browse files Browse the repository at this point in the history
  • Loading branch information
mirka committed Feb 22, 2022
1 parent f98d14d commit 354c730
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/components/src/ui/context/context-connect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* External dependencies
*/
import { uniq } from 'lodash';
import type { ReactChild, ReactNode, Ref } from 'react';
import type { ForwardedRef, ReactChild, ReactNode } from 'react';

/**
* WordPress dependencies
Expand Down Expand Up @@ -36,7 +36,7 @@ type ContextConnectOptions = {
* @return The connected WordPressComponent
*/
export function contextConnect< P >(
Component: ( props: P, ref: Ref< any > ) => JSX.Element | null,
Component: ( props: P, ref: ForwardedRef< any > ) => JSX.Element | null,
namespace: string,
options: ContextConnectOptions = {}
): WordPressComponentFromProps< P > {
Expand Down

0 comments on commit 354c730

Please sign in to comment.