lexical
lexical copied to clipboard
Feature: File upload
I checked out the playground page and I did not see a file upload. However I can upload an image when dragged to the lexical editor.
Is there a way i can control that upload behaviour? Like speciying a custom dialog or webapi for it? Thanks
There's no magic here, really. If you want to upload with a dialog, just make a button that triggers a dialog. When the upload is complete (or whenever, as your needs require) insert a Lexical node that renders an HTML img tag or something to have the image show up in the editor.
Lexical doesn't provide this out of the box, but we can leave this open as a feature request to support this better.