amplitudejs icon indicating copy to clipboard operation
amplitudejs copied to clipboard

Waveforms Should Be URLs

Open danpastori opened this issue 3 years ago • 0 comments

Discussed in https://github.com/serversideup/amplitudejs/discussions/507

Originally posted by danpastori May 4, 2022

👉 Describe the problem

When generating a waveform, the audio file is loaded twice or is only loaded up to what is buffered. This leads to terrible UI since it's either two requests, or partially shown.

👥 Problem evidence & reach

Any user working with waveforms.

🥰 Describe the "impact" on users?

When displaying a waveform, we should allow the user to pass in a URL. We can generate waveforms using Amplitude Hosting and these will be SVGs making for much speedier, responsive players.

🏆 How to solve this problem

Allow for a waveform to be a URL for the audio file and encourage this. We will remove all waveform generating functionality and abstract it to a plugin. This will be a breaking change, but will lead to much cleaner code, smaller compiled sizes, and better UX.

💯 How do we validate the problem is solved?

A user can generate a waveform through Amplitude Hosting or their own provider and pass it along with an audio file so it loads instantly.

danpastori avatar May 04 '22 22:05 danpastori