You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
These fields should allow you to upload a file, image and video respectively. Once an image is uploaded, the ImageField should display the image. Once a video is uploaded the VideoField should use the browser's native capabilities to display a video player.
To support both large and small files, the upload operation should be configured to call a back-end API immediately after the user selects the file to upload. This configuration should probably be in the form of an event that is emitted on the field whereby you create a listener to perform the upload to the back end. During the upload, a progress indicator should be displayed. The back-end API will return a URL that can then be used to display (or link to) the file. We should be able to support any API: GraphQL, RESTful API, etc... by requiring that the upload work is performed by an Action.
An optional enhancement for the future is to have a configuration that instead uploads the file in the browser and then base64 encodes the file data in the form's values. This would most likely only be useful for small files, as large files would take up a lot of browser memory because the contents cannot be streamed. Moreover, transmitting these files in single chunks to say a back-end would be very slow.
The text was updated successfully, but these errors were encountered:
These fields should allow you to upload a file, image and video respectively. Once an image is uploaded, the ImageField should display the image. Once a video is uploaded the VideoField should use the browser's native capabilities to display a video player.
To support both large and small files, the upload operation should be configured to call a back-end API immediately after the user selects the file to upload. This configuration should probably be in the form of an event that is emitted on the field whereby you create a listener to perform the upload to the back end. During the upload, a progress indicator should be displayed. The back-end API will return a URL that can then be used to display (or link to) the file. We should be able to support any API: GraphQL, RESTful API, etc... by requiring that the upload work is performed by an Action.
An optional enhancement for the future is to have a configuration that instead uploads the file in the browser and then base64 encodes the file data in the form's values. This would most likely only be useful for small files, as large files would take up a lot of browser memory because the contents cannot be streamed. Moreover, transmitting these files in single chunks to say a back-end would be very slow.
The text was updated successfully, but these errors were encountered: