sarink / react-file-drop

React component for Gmail or Facebook -like drag and drop file uploader

Home Page:https://www.sarink.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Using frame prop

Falsen opened this issue · comments

Hello I am trying to use the "frame" prop without any success.

Frame must be of the type HTMLDocument but how can I generate an HTMLDocument inside render()? I was going to use document.getElementById, but I quickly realized that isn't an option since the HTML isn't yet rendered on the page in the render() function. So how can I create an HTMLElement inside the render function itself?

Could you please provide an example

@Falsen I don't understand your problem. You can pass a frame that is any html element or, the entire document. Just create a div somewhere, and pass that as the frame prop.