Replies: 1 comment 1 reply
-
Sorry. Honestly didn't know Discussion tab exists 🤣 I've went away from this issue just overriding the global class names like However one thing that I had on mind was to making all the keys in There are a lot of ways to style this library which is good so just wanted to have an open minded conversation. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello.
In my opinion styling the library in v7 can be a bit confusing, especially when you have TS yelling at you.
From my understanding if you use CSS modules the best way to style this library:
@import "~react-day-picker/lib/style";
in your SCSS module fileclassNames
prop.But now if you have generic typings for your SCSS like
[className: string]: string }
TS will obviously yell at you.The way I used to and I think is the most common would be to
But in this case it won't be happy, because all fields of the
ClassNames
type are required.Wonder what would be the best solution for that issue and what is the preferred way to go with the styling of this library.
Beta Was this translation helpful? Give feedback.
All reactions