fable-compiler / fable-react

Fable bindings and helpers for React and React Native
MIT License
275 stars 66 forks source link

JustifyContent should be made type safe just like AlignItems #150

Open MangelMaxime opened 5 years ago

jannesiera commented 5 years ago

It seems like a lot of CSSProps are typed by an obj or a string where they could benefit from more type safety. Is there a reason why they're not typed by a DU, for example?

MangelMaxime commented 5 years ago

It's because of Fable.React is one of the older libraries and at the time, we wanted to have a thin layer on top of React. So using obj make it easy to do that because the user can write center, 2px, calc(100vh - 3em), etc.

We are also a small team of core maintainer and can't do all the evolution ourself :)

Because we accepted making some of the properties type-safe, we would accept a PR converting more properties to be type-safe :)