Showpad-js Uploads on Android (and experience serve)
I'm following the sample at:
https://showpad.pages.showpad.io/showpad-js-lib/reference-v9.html#upload
This works on iOS and "web app" versions, popping up a save file dialog as expected.
However on all Android versions I test (multiple devices and os versions) the code silently fails and no dialog is shown.
This happens even on the most basic app:
window.onShowpadLibLoaded = () => {
uploadTest();
}
function uploadTest(){
const filename = 'filename.txt';
const file = new File(['file contents'], filename);
const upload = {
file: file,
filename: filename
};
const statusEmitter = window.ShowpadLib.upload(upload);
statusEmitter.on('queued', () => {});
statusEmitter.on('uploading', (data) => {});
statusEmitter.on('processing', () => {});
statusEmitter.on('success', (data) => {});
statusEmitter.on('failed', (error) => {});
}
As well as Android; this fails during testing via Showpad experience serve
Here I always get a success object back with the exact same data as in the docs.
I.e.
"id": "abc123",
"slug": "bdfklje739v930g0d"
I presume this is supposed to work on Android? Is there anything obviously wrong?
Thanks
-
Hi Malcom,
Thanks for reaching out. We'll create a support ticket out of your question, so we can follow up in detail on what might be the issue here.
Have a great day!
0
Please sign in to leave a comment.
Comments
1 comment