mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
13169f0987
Summary: This diff deletes ReactFeatureFlags.useViewManagerDelegatesForCommands, this has been enabled in prod for 9+ months changelog: [internal] internal Reviewed By: JoshuaGross Differential Revision: D28265338 fbshipit-source-id: 2f07cb83d6ef9191f9ebea52e230490ef98d6e2d
88 lines
3.0 KiB
Java
88 lines
3.0 KiB
Java
/*
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
package com.facebook.react.config;
|
|
|
|
/**
|
|
* Hi there, traveller! This configuration class is not meant to be used by end-users of RN. It
|
|
* contains mainly flags for features that are either under active development and not ready for
|
|
* public consumption, or for use in experiments.
|
|
*
|
|
* <p>These values are safe defaults and should not require manual changes.
|
|
*/
|
|
public class ReactFeatureFlags {
|
|
|
|
/**
|
|
* Should this application use TurboModules? If yes, then any module that inherits {@link
|
|
* com.facebook.react.turbomodule.core.interfaces.TurboModule} will NOT be passed in to C++
|
|
* CatalystInstanceImpl
|
|
*/
|
|
public static volatile boolean useTurboModules = false;
|
|
|
|
/**
|
|
* Should application use the new TM callback manager in Cxx? This is assumed to be a sane
|
|
* default, but it's new. We will delete once (1) we know it's safe to ship and (2) we have
|
|
* quantified impact.
|
|
*/
|
|
public static volatile boolean useTurboModulesRAIICallbackManager = false;
|
|
|
|
/** Should we dispatch TurboModule methods with promise returns to the NativeModules thread? */
|
|
public static volatile boolean enableTurboModulePromiseAsyncDispatch = false;
|
|
|
|
/*
|
|
* This feature flag enables logs for Fabric
|
|
*/
|
|
public static boolean enableFabricLogs = false;
|
|
|
|
/**
|
|
* Temporary feature flat to control a fix in the transition to layoutOnlyViews TODO T61185028:
|
|
* remove this when bug is fixed
|
|
*/
|
|
public static boolean enableTransitionLayoutOnlyViewCleanup = false;
|
|
|
|
/** Feature flag to configure eager initialization of Fabric */
|
|
public static boolean eagerInitializeFabric = false;
|
|
|
|
/** Feature flag to configure eager initialization classes of Fabric */
|
|
public static boolean eagerInitializeFabricClasses = false;
|
|
|
|
/** Enables Static ViewConfig in RN Android native code. */
|
|
public static boolean enableExperimentalStaticViewConfigs = false;
|
|
|
|
/** Enables a more aggressive cleanup during destruction of ReactContext */
|
|
public static boolean enableReactContextCleanupFix = false;
|
|
|
|
/** Enables JS Responder in Fabric */
|
|
public static boolean enableJSResponder = false;
|
|
|
|
/** Enables MapBuffer Serialization */
|
|
public static boolean mapBufferSerializationEnabled = false;
|
|
|
|
/** An interface used to compute flags on demand. */
|
|
public interface FlagProvider {
|
|
boolean get();
|
|
}
|
|
|
|
/** Should the RuntimeExecutor call JSIExecutor::flush()? */
|
|
private static FlagProvider enableRuntimeExecutorFlushingProvider = null;
|
|
|
|
public static void setEnableRuntimeExecutorFlushingFlagProvider(FlagProvider provider) {
|
|
enableRuntimeExecutorFlushingProvider = provider;
|
|
}
|
|
|
|
public static boolean enableRuntimeExecutorFlushing() {
|
|
if (enableRuntimeExecutorFlushingProvider != null) {
|
|
return enableRuntimeExecutorFlushingProvider.get();
|
|
}
|
|
|
|
return false;
|
|
}
|
|
|
|
/** Enables Fabric for LogBox */
|
|
public static boolean enableFabricInLogBox = false;
|
|
}
|