From 52530f05dfff0e2d93c940336faa70a9c6696006 Mon Sep 17 00:00:00 2001 From: Slapbox Date: Mon, 4 May 2020 03:30:29 -0400 Subject: [PATCH] Adds a warning about flex: 1 with @emotion/native (#1858) --- packages/native/README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/native/README.md b/packages/native/README.md index dfa879561..a7792f8be 100644 --- a/packages/native/README.md +++ b/packages/native/README.md @@ -128,6 +128,10 @@ class App extends React.Component { } ``` +## Gotchas + +- Note that the `flex` property works like CSS shorthand, and not the legacy `flex` property in React Native. Setting `flex: 1` sets `flexShrink` to `1` in addition to setting `flexGrow` to `1` and `flexBasis` to `0`. + ## Usage with `react-360` `@emotion/native` can also be used with `react-360` for styling VR applications. Check out [this](https://facebook.github.io/react-360/docs/setup.html) guide for setting up a `react-360` project.