How To Fix “‘event2/event-config.h’ file not found in React-Native”?
Are you having problems with the issue “‘event2/event-config.h’ file not found in React-Native“? How to fix it? In today’s article, I will provide solutions for you to solve the issues. Please follow the below steps to get the problem resolved now
How did “‘event2/event-config.h’ file not found in React-Native” occur?
‘event2/event-config.h’ file not found in React-Native
When you work with Error Solution, you may get the issue ‘event2/event-config.h’ file not found in React-Native. Don’t worry, we are here to provide you solutions in order to resolve your problem.
How to fix “‘event2/event-config.h’ file not found in React-Native”?
How to solve ‘event2/event-config.h’ file not found in react native ?
This problem is caused by updating the Xcode version. This problem is caused by flipper-folly file. This is the solution: With or without the flipper files. Follow the steps below to fix this error.
Solutions 1
This problem is caused by updating Xcode version. This problem is caused by flipper-folly file. This article will explain how to fix flipper files and without flipper files. Follow the steps below to fix this error.
Using Flipper File.
There is only one way to get a flipper file. Simply downgrade the flipper version. Simply open the Podfile located in your ios project folder, and change these lines of code.
use_flipper!({ 'Flipper-Folly' => '2.3.0' }) # update this part
post_install do |installer|
flipper_post_install(installer)
end
Next, we need to update our pods. Follow these steps.
pod update
OR
pod install
Remember to keep your cocoapods current.
sudo gem install cocoapods
This solution will fix your error.
Without Using Flipper File.
You don’t require a flipper file. You can comment out the following line of code. Simply open your Podfile within your ios project folder and comment these lines.
use_flipper!
post_install do |installer|
flipper_post_install(installer)
end
Next, we need to update our pods. Follow these steps.
pod update
OR
pod install
Remember to keep your cocoapods current.
sudo gem install cocoapods
Solution 2
It’s a flipper SDK problem. Facebook just released an update to flipper
, v74
, and added support for arm64
. Make sure that you’re using the most recent version.
-
Android:Move the
FLIPPER_VERSION
variable toandroid/gradle.properties
. For example,FLIPPER_VERSION=0.74.0
. In the android directory, run./gradlew clean
-
iOS:Call the use_flipper using a version in
iOS/Podfile
. For example,use_flipper!({ 'Flipper' => '0.74.0' })
. Start pod install in your ios directory. -
we can see how to setup flipper for
react-native
here: https://fbflipper.com/docs/getting-started/react-native
The 'event2/event-config.h' file not found
issue can be fixed with the above version.
Final words
The above are useful solutions that can help you fix “‘event2/event-config.h’ file not found in React-Native” problem, if you can’t solve it well. Please leave a message.