-
Hello, there.
Since I need the editor ref in order to dispatch the insert image command I'm using a "Plugin" that serves to set the editor instance reference. Is there a better way to accomplish what I'm trying to do here? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The approach you listed looks reasonable to me, we plan to work on drag & drop support for text, images and similar but it's still on the todo list (https://github.com/facebook/lexical/issues?q=is%3Aissue+drag). Lexical currently offers a command to handle the drop event -> |
Beta Was this translation helpful? Give feedback.
The approach you listed looks reasonable to me, we plan to work on drag & drop support for text, images and similar but it's still on the todo list (https://github.com/facebook/lexical/issues?q=is%3Aissue+drag).
Lexical currently offers a command to handle the drop event ->
DROP_COMMAND
. You can potentiallyregisterCommandListener
this command and handle the event there. The rest would be the same!