Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

114
Views
How can we use style prop in TouchableWithoutFeedback or TouchableWithNativeFeedback?

I want to give some style to the TouchableWithNativeFeedback , The style prop doesnot work although it works fine with the TouchableOpacity but it wont work with the native feedback. Is there any way we can make it work. I found a solution but I dont want to do it is there any other way.

The solution that I found in github.

link :

https://github.com/facebook/react-native/issues/8307

Answer:

I was having the same issue. But I wrapped the TouchableWithoutFeedback element with a view and styled the view instead. And I wrapped everything inside the TouchableWithoutFeedback with another view with a style identical to the parent view. This seems to have fixed it for me.

Thank you.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

This is not possible, since TouchableWithNativeFeedback does not have a style prop. This is documented here in the documentation.

The recommended pattern is the one you do not want to use (for whatever reason).

// the styling in the view of the child of TouchableWithoutFeedback
<TouchableWithoutFeedback onPress={onPress}>
   <View style={styles.button}>
     <Text>Touch</Text>
   </View>
</TouchableWithoutFeedback>
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!