Skip to content

Since document.execCommand is deprecated, what is the plan for future releases? #2214

Answered by gohabereg
FarooqAlaulddin asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @FarooqAlaulddin

execCommand is deprecated for quite a while, however there is still no suitable alternative. The same results might be achieved using Range API and Input Events Level 2 API. However, Range API implementation differs from browser to browser, and Input Events are not widely supported yet.

In the future we would like to have some robust interface provided by Editor.js API for inline tools, however that is really challenging problem as it requires to disabled default browser behaviour and fully simulate it with more modern APIs. So as for now, execCommand is a way to go

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by neSpecc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2211 on December 12, 2022 14:37.