marcbruederlin / particles.js

A lightweight, dependency-free and responsive javascript plugin for particle backgrounds.

Home Page:https://marcbruederlin.github.io/particles.js/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to destroy particles object

alangrainger opened this issue · comments

Is there a way to destroy the particles object? I can't see anything obvious in the code.

I have a single-page app, and switching between routes causes an error when it can't find the canvas object on the second page.

Thanks!

commented

I have the same problem with Angular ,Do you solve it? @alangrainger

@alangrainger @kainonly I'll put it on my list for the next few days.

commented

Thanks!

Do you guys have a minimal demo to reproduce the problem?

commented

https://github.com/kainOnly/ng-ezbit.
resize page go wrong after login,I want to destroy particles after a successful login.
tim 20180322231143

I just updated the library. You can now use the public destroy method (Particles.destroy()).

commented

Thank you for your help. The problem has been solved.

@alangrainger Is this solved for you too?