react-native icon indicating copy to clipboard operation
react-native copied to clipboard

fix(examples): fixing `XMLHttpRequest` file download example

Open mateoguzmana opened this issue 4 months ago • 1 comments

Summary:

The XMLHttpRequest example with a single file download doesn't seem to be working anymore. The test case is quite old so it seems like something changed in between with the example URLs.

  • Changing the URL for the example. Using another file from filesamples.com as it's already being used in the chunk file download example as well.
  • Adding an onerror callback as it was loading infinitely when something went wrong.

Changelog:

[INTERNAL] [FIXED] - fixing XMLHttpRequest file download example

Test Plan:

Using the rn-tester, see the before and after for comparison

Before and after videos

Before:

https://github.com/user-attachments/assets/01f89cd9-0f5e-4ddb-9ff2-c3e053be5413

After:

https://github.com/user-attachments/assets/59ef161c-d5ba-43e3-827e-e250cc663276

mateoguzmana avatar Oct 22 '24 05:10 mateoguzmana