Docs
AI
AI
allows you to select from a list of AI commands.
Installation
npm install @udecode/plate-ai
Usage
// ...
import { AIPlugin } from '@/registry/default/plate-pro/ai/ai/src/react/AIPlugin';
const editor = usePlateEditor({
id: 'ai-demo',
override: {
components: PlateUI,
},
plugins: [
...commonPlugins,
SelectionOverlayPlugin,
MarkdownPlugin.configure({ options: { indentList: true } }),
AIPlugin.configure({
options: {
scrollContainerSelector: '#scroll_container',
},
render: { aboveEditable: AIMenu },
}),
],
value: aiValue,
});