Closed X-Tender closed 4 years ago
I believe that this may be fixed by https://github.com/ianstormtaylor/slate/pull/3093, which has changed a lot of the logic in Slate and slate-react
especially. I'm going to close this out, but as always, feel free to open a new issue if it persists for you. Thanks for understanding.
Do you want to request a feature or report a bug?
Bug
What's the current behavior?
Slate crash with error
When inserting inline element via click Event and didn't call
preserveDefault
on the click Event, and changing thereadOnly
mode totrue
after that. When I click into the edit area and then toggle thereadOnly
mode the error did not occur.Example (Emoji example from website): https://codepen.io/XTender/pen/WMrEwJ?editors=1010
Sure the "Bug" can be omitted by using
e.preventDefault()
but I thought if this is the correct behavior if it doesn't.What's the expected behavior?
Should not crash :)