Play audio while loading

Asked

Viewed 22 times

0

Hello. When we use the element <audio> It only plays when it’s loaded 100%. I wanted to have an idea of how to make it play while still charging, to avoid the delay. Can you give me some information?

  • if you use the attribute preload=auto audio is loaded at page startup

1 answer

0

You can use the element <embed>, which has other properties, it would be something like:

<embed 
  src="/music/good_enough.mp3"
  loop="false"
  autostart="true">

You can reach the reference here.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.