Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis0
How can I get document.execCommand to work in browsers other than chrome? If I canāt, what are the alternatives?
https://code.sololearn.com/W8iBH8BAhwct/?ref=app Iām creating a text editor and using document.execCommand to generate and modify HTML. Unfortunately this doesnāt seem to be available in browsers like IE and Firefox. Iāve searched for alternatives or solutions to this problem but havenāt had any luck. If someone has a solution or alternative to share that would be very much appreciated.
1 Resposta
+ 1
It is supposed to be (partially) supported by major browsers, according to this page on MDN (Mozilla Developers Network):
https://developer.mozilla.org/en-US/docs/Web/API/document/execCommand
Check it, and make sure to use it the right way and only for/with command widely supported ;)