draft-convert
draft-convert copied to clipboard
Increase visual accuracy of convertFromHTML flat mode
Fixes https://github.com/HubSpot/draft-convert/issues/113
Adds two fixes to flat: true mode of convertToHTML:
- If in flat mode within a block starting with text as a direct child and a sibling element to that text is identified as a block, add a block divider of its type.
- If a non-empty block has a
<br>tag as a last child, don't add the closing block separator to the chunk.