code-input icon indicating copy to clipboard operation
code-input copied to clipboard

Improve key events being listened to in plugins

Open WebCoder49 opened this issue 3 months ago • 0 comments

Key events used in plugins are not always the best choices. For example, keydown is listened to for enter key presses to create newlines in the indent plugin, but beforeinput or input would be better and allow for external code to intercept enter key presses differently with preventDefault. The code for this is here and used for Ctrl+Enter functionality here.

This is a breaking change which would interfere with code using the library and other plugins, but would allow functionality otherwise impossible.

WebCoder49 avatar Sep 21 '25 12:09 WebCoder49