Closed jelhan closed 9 months ago
@jelhan thanks a lot for doing that! It's certainly more helpful. How about also adding the ability to use CSS variables - what I mentioned in Discord:
Partial<CSS.Properties> | Partial<CSS.PropertiesHyphen> | { readonly [key: `--${string}`]: string }
@jelhan thanks a lot for doing that! It's certainly more helpful. How about also adding the ability to use CSS variables - what I mentioned in Discord:
Partial<CSS.Properties> | Partial<CSS.PropertiesHyphen> | { readonly [key: `--${string}`]: string }
Missed that this is needed in addition.to support CSS custom properties. And it seems we are missing test coverage for that use case as well. A PR fixing it is highly welcome.
Improves the typing for CSS styles using the
csstype
package.In case you are running into an issue that a valid CSS style is not allowed by the types, please update the indirect
csstype
dependency to a latest version. E.g. you could do so by regenerating the lockfile. If that does not help, thecsstype
package provides documentation how to deal with that situations: https://www.npmjs.com/package/csstype#what-should-i-do-when-i-get-type-errorsThanks a lot to @boris-petrov for suggesting this via Discord.