Skip to content

fedorovsky/draft-js-link-detection-plugin

Repository files navigation

draft-js-link-detection-plugin

Installation:

npm i draft-js-link-detection-plugin

Usage:

import Editor from 'draft-js-plugins-editor';
import createLinkDetectionPlugin from 'draft-js-link-detection-plugin';

const linkDetectionPlugin = createLinkDetectionPlugin();
const plugins = [linkDetectionPlugin];

<Editor
    ref={editorRef}
    plugins={plugins}
    editorState={editorState}
    onChange={handleChangeEditor}
/>