We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello, I have tried fetch API from background JS script. but not working.
addEventListener("fetchTest", async (resolve, reject, args) =>{ try { console.log('fetch start'); const response = await fetch('https://jsonplaceholder.typicode.com/todos/1'); if(response.ok){ console.log('fetch success'); }else{ console.log('fetch failed'); } resolve(); } catch (error){ console.log('error caught'); console.error(error); reject(); } });
BackgroundRunner.dispatchEvent({ label: 'com.example.background.task', event: 'fetchTest', details: {}, });
I have tried this on Android Studio emulator (Android ver 13) but only the messages 'fetch start' and 'error caught' appears on logcat. Thanks!
The text was updated successfully, but these errors were encountered:
Hey @theproducer thank you for looking into this. When can we expect a new version with the fix?
Sorry, something went wrong.
theproducer
Successfully merging a pull request may close this issue.
Hello, I have tried fetch API from background JS script. but not working.
I have tried this on Android Studio emulator (Android ver 13) but only the messages 'fetch start' and 'error caught' appears on logcat.
Thanks!
The text was updated successfully, but these errors were encountered: