TVke / react-native-tailwindcss

A react-native style system based on TailwindCSS
https://tvke.github.io/react-native-tailwindcss/
MIT License
565 stars 34 forks source link

Web: Invalid style property of "direction" #54

Open markstreich opened 3 years ago

markstreich commented 3 years ago

Hi, I'm getting the following warning in the web browser console with expo web:

index.js:1 Warning: Invalid style property of "direction". Did you mean "writingDirection"?
console.<computed>  @   index.js:1
printWarning    @   warning.js:30
...../node_modules/fbjs/lib/warning.js.warning  @   warning.js:51
error   @   validate.js:23
validate    @   validate.js:61
(anonymous) @   StyleSheet.js:50
create  @   StyleSheet.js:45
...../node_modules/react-native-tailwindcss/tailwind.js @   tailwind.js:121
__webpack_require__ @   bootstrap:789
fn  @   bootstrap:100
...../node_modules/react-native-tailwindcss/index.js    @   index.js:1
__webpack_require__ @   bootstrap:789
fn  @   bootstrap:100
...../App.js    @   bootstrap:856
__webpack_require__ @   bootstrap:789
fn  @   bootstrap:100
...../node_modules/expo/AppEntry.js @   AppEntry.js:1
__webpack_require__ @   bootstrap:789
fn  @   bootstrap:100
1   @   log.js:59
__webpack_require__ @   bootstrap:789
(anonymous) @   bootstrap:856
(anonymous) @   bootstrap:856

I think it needs to be run in development mode, so you won't see the warning in the snack preview, but here's a minimal reproduction anyway:

https://snack.expo.io/@markstreich/e34409

TVke commented 3 years ago

Hi @markstreich

Thank you for noticing I think a simpel change cn fix this warning. The property direction is indeed used in the overview and apparently has changed to writingDirection. What is the react native version you are using?

greetings Thomas

markstreich commented 3 years ago

Hi Thomas,

I'm using Expo 39, which I uses RN 0.63.2

TVke commented 3 years ago

Hi @markstreich

I presume this direction property was changes in a release. I would accept a PR to fix this.

greetings Thomas

skotchpine commented 3 years ago

Hi, @TVke here's a fix: https://github.com/TVke/react-native-tailwindcss/pull/57

teovillanueva commented 3 years ago

Hello! This is still an issue. Will the PR be merged? If help is needed i can help

TVke commented 3 years ago

Hi

The PR was closed by the creator so I don't think it was finished so if you create a new one I will happily merge the commit and publish a patch release.