uploadcare / file-uploader

Stack-agnostic library for uploading, processing, and editing images on-the-fly
https://uploadcare.com/docs/file-uploader/
MIT License
83 stars 13 forks source link

prevent flash of unstyled content when the file-uploader is being loaded #409

Open halafi opened 1 year ago

halafi commented 1 year ago

right now when you load the page with e.g. lr-file-uploader-regular it takes a while for it to initialise (especially if you use cdn for the css file) which results in a flash of missing content.

is there a recomended approach for server side rendering? or exposed API that can be used to show e.g. spinner or loader before the component is initilalised?

thanks

nd0ut commented 1 year ago

At the moment, we don't have any API like that, but I think we could create an event that fires when styles are loaded so that you can add your own custom loader.