Open tablatronix opened 8 years ago
Remove newline formatting solution is flawed.
Hi, @tablatronix having the same problem with newlines dissapearing inside <pre>
Found the same solution as you did, removing .replace in plugin.js...
//htmlData = editor.getData(1).replace(/(\r\n|\n|\r)/gm,""); // remove all linebreaks to prevent some parsing issues
htmlData = editor.getData(1);
I am now wondering if this introduces any other issues, as the comment states that newlines are removed to 'prevent some parsing issues'.... did you encounter any of those?
I cant say, i never wound up using this in production.
similar to #11
if you have a
pre
block all newlines in it are removed when switching to markdown.Reproduce
goto demo
http://hectorguo.com/CKEditor-Markdown-Plugin/ enter multi line text, highlight, click format combo change to
formatted
switch to markdown and see that all formatting is removed, newlines are gone text becomes single line inline looking.