Generic typings #57
TheOnlyBeardedBeast
started this conversation in
Ideas
Replies: 0 comments
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.
-
Hi guys, thanks for the good work.
I noticed that every color has its own type generated while a generic type could be made.
example usage
ColorShades<"slate">I use these generics in a function to generate right typings for color name transformation. (using same name for a neutral color but using different colors in different themes with stiches)
example usage
transformColor(slateDark, 'slate', 'neutral')Not sure if all this helps anyway, but it could reduce the generated typing file sizes, at least.
Beta Was this translation helpful? Give feedback.
All reactions