Skip to content

Mentions Plugin ​

User mentions triggered by @.

Installation ​

bash
npm install on-codemerge

Basic Usage ​

javascript
import { Editor, MentionsPlugin } from 'on-codemerge';

const editor = new HTMLEditор(container);
/* use plugins: [MentionsPlugin()] in Editor(...) */

Demo ​


Public API (v2) ​

Factory: MentionsPlugin(mentions?) — options: Mention[] (default DEFAULT_MENTIONS).

Command
insertMentioneditor.command('insertMention')

Keyboard shortcuts ​

ShortcutCommand
Mod-Shift-2insertMention

Note: Editor is Editor, not HTMLEditor.

Released under the MIT License.