Skip to content

Added support for multiple particles on a single page #21

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 14, 2018
Merged

Added support for multiple particles on a single page #21

merged 1 commit into from
Jan 14, 2018

Conversation

xkisu
Copy link

@xkisu xkisu commented Jan 12, 2018

For a client project the client wanted 2 instances of particles on either side of a page with different colors. I realized that this was not possible with the way vue-particles was currently configured.

To make it possible I made it so that the ID for the root element is a reactive Vue data property with a randomly generated number at the end. This way there can be several instances on the page without them clashing.

@creotip creotip merged commit fefae8b into creotip:master Jan 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants