Skip to content

htmlToDraft adds extra space to text node #104

@ezheniko

Description

@ezheniko
console.log(html);
const contentBlock = htmlToDraft(html);
contentBlock.contentBlocks.forEach(i => console.log(i.toJS()));

first console.log prints this

<ul> 
 <li>sdf</li> 
</ul>

console.log for contentBlock prints this

characterList: (4) [{…}, {…}, {…}, {…}]
data: {}
depth: 0
key: "8fh3d"
text: "sdf "
type: "unordered-list-item"

as you see it adds extra space to text inside <li>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions