import * as React from "react"; import type { Experiment, Result, FeatureResult, JSONValue, FeatureDefinition, Context, WidenPrimitives } from "@growthbook/growthbook"; import { GrowthBook } from "@growthbook/growthbook"; export type GrowthBookContextValue = { growthbook: GrowthBook; }; export interface WithRunExperimentProps { runExperiment: (exp: Experiment) => Result; } /** @deprecated */ export type GrowthBookSSRData = { attributes: Record; features: Record; }; export declare const GrowthBookContext: React.Context; /** @deprecated */ export declare function getGrowthBookSSRData(context: Context): Promise; /** @deprecated */ export declare function useGrowthBookSSR(data: GrowthBookSSRData): void; export declare function useExperiment(exp: Experiment): Result; export declare function useFeature(id: string): FeatureResult; export declare function useFeatureIsOn = Record>(id: string & keyof AppFeatures): boolean; export declare function useFeatureValue(id: string, fallback: T): WidenPrimitives; export declare function useGrowthBook = Record>(): GrowthBook; export declare function FeaturesReady({ children, timeout, fallback, }: { children: React.ReactNode; timeout?: number; fallback?: React.ReactNode; }): React.ReactElement; export declare function IfFeatureEnabled({ children, feature, }: { children: React.ReactNode; feature: string; }): React.ReactElement | null; export declare function FeatureString(props: { default: string; feature: string; }): React.ReactElement; export declare const withRunExperiment: {

(Component: React.ComponentType

): React.ComponentType>; displayName: string; }; export declare const GrowthBookProvider: React.FC>; //# sourceMappingURL=GrowthBookReact.d.ts.map