draft-js-markdown-shortcuts-plugin icon indicating copy to clipboard operation
draft-js-markdown-shortcuts-plugin copied to clipboard

Deleting a markdown block in the very first line

Open mxstbr opened this issue 7 years ago • 1 comments

When I type a hash as the very first character, which converts the first line to a heading, I can never make that line leave heading mode again. Pressing backspace when there's no content left doesn't do anything. (the same thing is true for all other blocks too, like code)

Could we do something like: When the cursor is at the very first position in the editor and backspace is pressed revert that block to unstyled?

mxstbr avatar Jul 19 '17 23:07 mxstbr

I fixed this in my fork, feel free to cherry-pick the commit to upstream: https://github.com/withspectrum/draft-js-markdown-plugin/pull/3 a4ef4ec

mxstbr avatar Sep 22 '17 08:09 mxstbr