Hacker News new | ask | show | jobs
by wcarss 1834 days ago
Some potential things to watch for:

- try not to obtain and initialize the audio context until the triggering event has occurred

- make sure the audio context + playback occurs directly as a result of the triggering event. If the event just sets some state, and then something else is periodically watching for that state to change, it may fail. A workaround here is to just mute+play some sound on that first tap, then you're good for any later Audio contexts created+initiated however you'd like.