Inefficient Color Generator Code #1015
sphinxrave
started this conversation in
Ideas / feature requests
Replies: 1 comment
-
|
As you can see, there are different functions and variables being used for each color name, so it can't be one function to use a list of color names. |
Beta Was this translation helpful? Give feedback.
0 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.
-
Weird looping behavior at
daisyui/src/colors/functions.js
Line 19 in 66ee475
The foreach shouldn't be looping over the primary-focus, secondary-focus etc etc generators. It should just operate on the list of colors provided, and then the generators should fill in the non-provided colors in one go.
It's fine as a preprocessor step, but, well, the only reason I care is that I'm trying to use that function at runtime and noticing it is incredibly expensive.
Beta Was this translation helpful? Give feedback.
All reactions