(providedRef?: React.RefObject<TRef>)
| 9 | * @type TRef The type of the RefObject which should be created. |
| 10 | */ |
| 11 | export function useProvidedRefOrCreate<TRef>(providedRef?: React.RefObject<TRef>): React.RefObject<TRef> { |
| 12 | const createdRef = React.useRef<TRef>(null) |
| 13 | return providedRef ?? createdRef |
| 14 | } |
no outgoing calls
no test coverage detected