bevacqua / woofmark

:dog2: Barking up the DOM tree. A modular, progressive, and beautiful Markdown and HTML editor
https://bevacqua.github.io/woofmark
MIT License
1.62k stars 74 forks source link

runCommand() runs function(chunks, mode), not function(mode, chunks) #29

Closed jywarren closed 7 years ago

jywarren commented 8 years ago

Unless I've made some mistake:

editor.runCommand(function(mode, chunks) { console.log(mode, chunks) })
> HtmlChunks {before: "<p>", startTag: "", selection: "", endTag: "", after: "lalalala</p>↵"…} "wysiwyg"
bevacqua commented 8 years ago

You are right. We should probably leave it be and fix the documentation.

jywarren commented 7 years ago

Fixed in #31.