I'm using the quill 1.3.7 package and try to add keybindings:
const bindings = {
handleEnter: {
key: 13,
handler: function (range, context) {
console.log("Example also not working");
}
}
}
var options = {
theme: 'snow',
modules: {
history: {
delay: 500,
userOnly: true
},
clipboard: {
matchers: [['BR', lineBreakMatcher]]
},
keyboard: {
bindings: bindings
}
}
};
quillEditor = new Quill(editor.value, options);
Logging quillEditor.keyboard.bindings even prints the added bindings. But pressing the keys is not executing the handler functions.