I have a project on React.js https://spyhere.github.io/build_beta_0.7/.
This is purely my idea. I found a problem that I don’t know how to play a sound without waiting to React to resolve the promise. As a result, I have an issue where some sound shots are delayed and even omitted.
I’m talking about “reading” button on high speed (“Expert”), though it’s not actually high speed, it’s just 90 beats per minute.
Another problem is a bug when you click to read or practice for the first time after loading the page and React is starting to load audio, so it is a huge delay.
Is there a way to preload audio, so it will be ready to play instantly?
I tried to google this thing and apparently found nothing useful. I’m using the recommended method with “audio tag” and ref.
I can provide code if it’s needed. Thanks.