Skip to content
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

duplicates when auto-generating patterns #34

Open
theme1256 opened this issue May 28, 2020 · 1 comment
Open

duplicates when auto-generating patterns #34

theme1256 opened this issue May 28, 2020 · 1 comment

Comments

@theme1256
Copy link

I have an issue with the auto-generation of patterns.
Sometimes it generates the same pattern twice, which kinda defeats the purpose.

In my implementation, it happens more often than, what might be good.

image

@barath99
Copy link

barath99 commented Jul 20, 2021

You can create an array of patterns as a workaround for this issue, like below:

let patterns = [ draw('square', '#1f77b4'), draw('line', '#ff7f0e'), draw('triangle', '#2ca02c')]

And accessing the elements through a loop might solve this issue of duplicates.

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

No branches or pull requests

2 participants