scottschiller / SoundManager2

A JavaScript Sound API supporting MP3, MPEG4 and HTML5 audio + RTMP, providing reliable cross-browser/platform audio control in as little as 12 KB. BSD licensed.
http://www.schillmania.com/projects/soundmanager2/
Other
4.99k stars 769 forks source link

amp-audio #228

Open akanik opened 6 years ago

akanik commented 6 years ago

I'm new to the project but I was wondering if there are any options to serve amp-audio tag instead of audio when dealing with Google AMP?

I've looked through the documentation and current issues and can't seem to find anything about this.

scottschiller commented 6 years ago

Pardon late follow-up, here. 😅

From what I see, it looks like the AMP audio stuff is a substitute or wrapper for HTML5 <audio>. If you were using SM2 inside AMP somehow (and I'm not familiar with it / not sure if you can have third-party libraries like SM2 inside AMP), you'd just write plain old HTML links to MP3 files and SM2 would handle the click and playback and whatnot from there; you wouldn't need to write AMP HTML.

I suspect if you're using AMP, you can just use their amp-audio stuff and they will render the UI and handle playback; you probably don't need SM2 at all!