More small README improvements

pull/363/head
Jeroen Akkerman 3 years ago
parent 551c84bc01
commit f004c2d0c3

@ -299,8 +299,8 @@ const editor = new EasyMDE({
el.setAttribute('data-keystrokes', 0); el.setAttribute('data-keystrokes', 0);
}, },
onUpdate: (el) => { onUpdate: (el) => {
let keystrokes = Number(el.getAttribute('data-keystrokes')) + 1; const keystrokes = Number(el.getAttribute('data-keystrokes')) + 1;
el.innerHTML = keystrokes + " Keystrokes"; el.innerHTML = `${keystrokes} Keystrokes`;
el.setAttribute('data-keystrokes', keystrokes); el.setAttribute('data-keystrokes', keystrokes);
}, },
}], // Another optional usage, with a custom status bar item that counts keystrokes }], // Another optional usage, with a custom status bar item that counts keystrokes
@ -369,9 +369,10 @@ const easyMDE = new EasyMDE({
className: "fa fa-bold", className: "fa fa-bold",
title: "Bold", title: "Bold",
}, },
"italics", // shortcut to pre-made button
{ {
name: "custom", name: "custom",
action: function customFunction(editor) { action: (editor) => {
// Add your own code // Add your own code
}, },
className: "fa fa-star", className: "fa fa-star",

Loading…
Cancel
Save