You could try maybe initializing the player inline:
<button onClick={() => document.getElementById('player').play()}>Play</button>
I don't know exactly if this helps
2.1m questions
2.1m answers
60 comments
57.0k users