Replies: 1 comment 5 replies
-
If you want to un-register a plugin, you should "destroy" it. const wavesurfer = Wavesurfer.create({
// ...
})
const timeline = TimelinePlugin.create({
// ...
})
// Register the plugin for the first time
wavesurfer.registerPlugin(timeline)
// Afterwards
// Un-register the plugin
timeline.destroy()
// Register a new instance
const newTimeline = TimelinePlugin.create({
// ...
})
wavesurfer.registerPlugin(newTimeline) |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello.
At first, I registered a timelineplugin to wavesurfer.
Additionally, I'd like to replace it with another one when a user zooms waveform.
I updated minPxPerSec with wavesurfer.zoom() method.
But I'm not sure how to update wavesurfer plugin.
I used registerPlugin method. But I realized that it is for add new plugins to wavesurfer not to update it.
Can you recommend a solution for me?
Beta Was this translation helpful? Give feedback.
All reactions