Slate: 'Select All' + 'Delete' results to Error in rich text example

Created on 9 May 2019  路  5Comments  路  Source: ianstormtaylor/slate

Do you want to request a _feature_ or report a _bug_?

Bug

What's the current behavior?

In rich text example, selecting all the text inside the editor and then deleting it results in an error.

Screenshot from 2019-05-09 19-34-32

What's the expected behavior?

Should work properly without any errors.

bug

Most helpful comment

Sorry about that folks, just released a fix to the slate-react-placeholder to prevent this. And I've added a backwards compatible deprecation warning as @Jarred-Sumner suggested as well, so it will work with the old format but log a warning.

All 5 comments

Just started using this library and encountered the very same issue. 馃

I think it's the recent change where mark.type is now type for decorations

Might be worth making it backwards compatible for now and adding a warning or something

Sorry about that folks, just released a fix to the slate-react-placeholder to prevent this. And I've added a backwards compatible deprecation warning as @Jarred-Sumner suggested as well, so it will work with the old format but log a warning.

@ianstormtaylor , awesome! Thank you very much for such a quick reaction.

Any change that this issue is related to this problem?..

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AlexeiAndreev picture AlexeiAndreev  路  3Comments

ianstormtaylor picture ianstormtaylor  路  3Comments

vdms picture vdms  路  3Comments

markolofsen picture markolofsen  路  3Comments

bengotow picture bengotow  路  3Comments