Quill inserts a useless line-break before the <ul> element
See original GitHub issueUnfortunately quill insert a line-break if you paste the following html into the editor:
<p>Simple list:</p><ul><li>item one</li><li>item two</li></ul><p><br></p>
The behavior of pasteHTML()
or convert(), setContents()
is the same.
Steps for Reproduction
- Visit https://codepen.io/iice/pen/vQKrWY
- change line in js to
var html = <p>Simple list:</p><ul><li>item one</li><li>item two</li></ul><p><br></p>;
- Watch what happens in the Viewer
Expected behavior:
Quill should not insert an line-break before the <ul>
- because this sums up.
The first time it insert a line-break, then we save it, then quill inserts the second line-break, we save again, and so on…
Actual behavior:
Simple list:
- item one
- item two
Platforms:
Chrome 79 Windows 10
Version: 1.3.7
Run Quill.version
to find out
Issue Analytics
- State:
- Created 4 years ago
- Reactions:7
- Comments:11
Top Results From Across the Web
How to prevent react-quill to insert a new line before list when ...
write a line, followed by a bullet list · click save to store the content to external storage · click clear to remove...
Read more >Quill, Shift-Enter and <br> tags
This means that pointless, useless but nevertheless harmless <br> might be hidden in the edited document forever (or until deleted by moving ...
Read more >react-quill - UNPKG
The CDN for react-quill. ... return this;\n }\n // Since it does not matter if we insert before or after deleting at ......
Read more >Untitled
2nd ashes test 2013 live streaming, Dragon knight dota 2 item guide, Barba blanca ... Dietetyk krosno ul lewakowskiego, Hp procurve 2610-48 default...
Read more >Untitled
Captain planet heart useless, Iriya no sora ufo no natsu capitulo 6, Fotoweek dc 2010, ... Sled dogs skis, Periodic table of elements...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I fixed it by disabling matchVisual, but I think we should find better solution.
it a appears as though that was the ultimate solution in later versions of quill: https://github.com/quilljs/quill/commit/3897c981fcabc599ce3b90793a33d40c4fa25fee