Hi can you please explain what exactly you need to do with the audio?
In HTML you could do this:
<audio controls>
<source src="https://cdn.islamic.network/quran/audio/128/ar.alafasy/1.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
to let the user use the audio.
If it has to do with React.js (as you tagged), this post should help you out.
To play an Audio File onClick, just take a look at the following example:
import React from 'react';
function App() {
let audio = new Audio("/christmas.mp3")
const start = () => {
audio.play()
}
return (
< div >
<button onClick={start}>Play</button>
</div >
);
}
export default App;
This example was provided in a duplicate found here by a user named hunter.