Open MaximBelov opened 1 year ago
Hey, I'd like to make a PR to fix this bug but I keep getting 403s when I try to push the feature branch. Any idea what's wrong / if this repo is even active? I'm curious how you were able to publish no problem.
@Blasterdude I dont see your fork of this plugin
1 Make fork 2 Create branch and push commits 3 Create PR
Ah okay thanks, not used to having to fork the repo to make a PR but makes sense. Is this repo even maintained currently? The last commit appears to be from last year.
I really hope that someone will merge my changes
You can use your forked version like this https://github.com/MaximBelov/cordova-plugin-advanced-http-lab/blob/8a8caba1070babae54f10eafd034e73dadb30e93/package.json#L54
Hi @MaximBelov, would you please explain why you created those two new functions? Asking, because uploadFile
and downloadFile
are short-hand functions for sendRequest
(see https://github.com/silkimen/cordova-plugin-advanced-http#sendrequest) which is basically doing the same. Except it doesn't support progress callback yet, but this is implemented in #466. Did I miss something in your PR?
Hi @silkimen You are right
I removed new functions
I added progress callback for uploadFile and downloadLoad methods
@silkimen
Examples:
download file https://github.com/MaximBelov/cordova-plugin-advanced-http-lab/blob/main/src/app/home/home.page.ts#L67
upload file https://github.com/MaximBelov/cordova-plugin-advanced-http-lab/blob/main/src/app/home/home.page.ts#L78
We can simply implementation without providing a callback cordova.fireDocumentEvent('onProgress', {transferred: 100 , total: 1000});
What did you think?
What about abort
? Is there a possibility to abort the download?
source: https://github.com/silkimen/cordova-plugin-advanced-http/pull/466
Demo: https://github.com/MaximBelov/cordova-plugin-advanced-http-lab
PR to Awesome Cordova Plugins: https://github.com/danielsogl/awesome-cordova-plugins/pull/4512