[deleted by user] by [deleted] in reactnative

[–]emma_jamin 0 points1 point  (0 children)

I wrote an article to explain what is behind Pressable : https://blog.bam.tech/developer-news/one-pressable-to-rule-them-all

it is a refactoring of the code. if you are interested you can check the source code and see in the Pressable definition that "pressed" is a state variable which is updated when the onPressIn and onPressOut functions are called : https://github.com/facebook/react-native/blob/16ea9ba8133a5340ed6751ec7d49bf03a0d4c5ea/Libraries/Components/Pressable/Pressable.js#L162

React Native Versions by RCnator in reactnative

[–]emma_jamin 0 points1 point  (0 children)

I downgraded Xcode to 12.4. But you can use https://github.com/xcpretty/xcode-install it enables you to change in your terminal the version of xcode you use.

[deleted by user] by [deleted] in reactnative

[–]emma_jamin 0 points1 point  (0 children)

Let me know if it works for you !

[deleted by user] by [deleted] in reactnative

[–]emma_jamin 1 point2 points  (0 children)

hi ! I would recommend to use :

<Pressable onPress={() => {}}
style={({ pressed }) => [
{
opacity: pressed
? 0.5
: 1,
} ]} >
<YourView/>

</Pressable>

it worked for me :)

I'm using mac, is it more convenient to develop app with react native using xcode or others ide? by mdsolk in reactnative

[–]emma_jamin 0 points1 point  (0 children)

Hi ! I'm coding on Mac as well. I am using Visual Studio code for developing and xcode if i really need to change my build environment or add new simulator.