UNPKG

@lexical/react

Version:

This package provides Lexical components and hooks for React applications.

10 lines (8 loc) • 432 B
/** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ import{mountSlotContainer as r,unmountSlotContainer as t}from"lexical";import{useCallback as i}from"react";function n(n,o,e){return i(i=>{if(i){const f=r(n,o,e,i);if(f)return t.bind(null,n,o,f)}},[n,o,e])}export{n as useLexicalSlotRef};