peaks.js icon indicating copy to clipboard operation
peaks.js copied to clipboard

React wrapper for peaks.js?

Open larrywal opened this issue 4 years ago • 4 comments

Has anyone created something for this? Right now I'm using refs to interact with Peaks.js in my react app, but would love to have a react control.

larrywal avatar Nov 12 '20 16:11 larrywal

There's a demo of how to use Peaks.js in React here: https://github.com/chrisn/peaksjs-react-example

chrisn avatar Nov 12 '20 16:11 chrisn

Thanks! So helpful. From looking through, I think for just a basic waveform rendering, I can take waveform.jsx and use it directly...

I do need to use seek and zoom, but if I pass those in to waveform as properties, and then in componentDidUpdate, if the file hasn't changed but the zoom/seek have, I could just call those functions directly on the element.

Sound right?

larrywal avatar Nov 12 '20 16:11 larrywal

@chrisn Any chance for a Vue example?

rowild avatar Jun 18 '21 18:06 rowild

@rowild Giovanni Candeo has a working vue.js example: https://github.com/candeogi/peaks-vue-demo It's very bare-bones but shows some basic options.

suterma avatar Aug 21 '22 21:08 suterma