infernojs / inferno

:fire: An extremely fast, React-like JavaScript library for building modern user interfaces

Home Page:https://infernojs.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Why remove CSSProperties in 8.0?

tolg opened this issue · comments

commented

CSSProperties is a vary handy type when coding some HTML element style, but I found that inferno 8.0 changed the style property's type to any. What's the consideration of this changing?

Yeah, I'm planning to add them back, but need to think how to get it done nicely.
React.CssProperties is based on this package: https://github.com/frenic/csstype
which types them like textAlign: 'middle', in inferno that would be: text-align: 'middle', or it could be given as style string

Oh it seems it supports types by hyphen https://github.com/frenic/csstype 🤩

This will be fixed in 8.0.3