@blocknote/react
Version:
A "Notion-style" block-based extensible text editor built on top of Prosemirror and Tiptap.
11 lines (10 loc) • 427 B
TypeScript
import { useLayoutEffect } from "react";
/**
* `useLayoutEffect` in the browser, `useEffect` under SSR — where
* `useLayoutEffect` cannot run and React warns.
*
* Used for latest-ref updates: the ref must be current before any layout
* effect can trigger an editor event, or a subscription could still invoke
* the previous render's callback.
*/
export declare const useIsomorphicLayoutEffect: typeof useLayoutEffect;