flutter_uploader icon indicating copy to clipboard operation
flutter_uploader copied to clipboard

Platform request: web support

Open daniel-vera-g opened this issue 5 years ago • 4 comments

As I could see from the pub description, flutter web is currently not supported.

Nevertheless, it would be great to support also web :smile:

Looking forward for your take on it.

daniel-vera-g avatar Sep 16 '20 15:09 daniel-vera-g

How would you handle the upload in the background on web, using a web worker or similar?

ened avatar Sep 16 '20 15:09 ened

How would you handle the upload in the background on web, using a web worker or similar?

Yeah, a web worker with an asynchronous upload using the web File API sounds good :+1:

daniel-vera-g avatar Sep 19 '20 07:09 daniel-vera-g

@daniel-vera-g can you start collecting links / demos or sample code even for this ticket? There is more work to be done before this can start (e.g. unified plugin transition, iOS fixes) and the transfer to flutter community as a whole.

ened avatar Sep 19 '20 11:09 ened

@daniel-vera-g can you start collecting links / demos or sample code even for this ticket? There is more work to be done before this can start (e.g. unified plugin transition, iOS fixes) and the transfer to flutter community as a whole.

Well, regarding the File upload itself:

  1. File Dart API: https://api.dart.dev/stable/2.9.3/dart-html/File-class.html
  2. Example js upload process: https://developer.mozilla.org/en-US/docs/Web/API/File/Using_files_from_web_applications

Regarding web workers, MDN also has good documentation:

  • https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Using_web_workers
  • https://developer.mozilla.org/en-US/docs/Archive/Using_workers_in_extensions

daniel-vera-g avatar Sep 25 '20 19:09 daniel-vera-g