editextock
Version:
This is a Text Editor.
19 lines (18 loc) • 668 B
TypeScript
import { ReactNode, FC } from "react";
import { Content, Editor } from "@tiptap/react";
interface EditorInstanceType {
editor: Editor | null;
setEditorContent: (content?: Content) => void;
updateContentHTML: (editor: Editor) => void;
contentHTML?: string;
updateContentJson: (editor: Editor) => void;
contentJson?: object;
content: Content | undefined;
setContent: (content: Content | undefined) => void;
}
export declare const EditorContext: import("react").Context<EditorInstanceType>;
export declare const EditorProvider: FC<{
children: ReactNode;
}>;
export declare const useEditorInstance: () => EditorInstanceType;
export {};