Open brentvatne opened 3 years ago
Cosign, I thought that this is how it was working when we added it.
I'm not sure what the best way to dot his is (maybe @fkgozali @alloy @orta or @thymikee know)
Just exclude Flipper from Podfile (is a ruby file)
https://github.com/facebook/flipper/issues/1326#issuecomment-788223247
Introduction
I noticed that iOS release builds became a lot slower since React Native 0.62, and it turns out that a lot of this can be explained by Flipper. By leaving Flipper out, I was able to see a ~50% reduction in build time on a simple project on my local machine and similar results on CI.
Local build times
A brand new app, with
yarn ios --configuration Release
on a Macbook Pro with 2.4 GHz 8-Core Intel Core i9:(ymmv depending on project complexity and other factors, of course)
CI build times
In a less powerful environment (Intel(R) Xeon(R) CPU E5-2697 with 6 cores available to VM), the same project had the following build times:
Details
It would be convenient to have some mechanism to exclude Flipper from CocoaPods when running
pod install
. We could wire up our build scripts locally and on CI to run, eg:pod install --production
orpod install --release
, or set and environment variable (SKIP_FLIPPER=1 pod install
). The flag option seems preferable, but listed both anyways.This could also be useful as a standard for other dependencies that the community builds in order to assist with development.
Discussion points
pod install
flags or environment variables.An aside
We should probably update the conditional include directives in the React Native template so they work in debug if Flipper is not installed. This works well for me: