import React from 'react'; /** * Higher-Order Component that initializes context storage. * * This HOC is designed for React Server Components and uses the configured * context adapter (default: React.cache()) for request-scoped storage. * * NOTE: `getPreviewContent` automatically populates context with preview data. * You may not need this HOC if you're only using that method. * * The HOC is useful for: * - Initializing context before any content fetching * - Ensuring context is available throughout the component tree * - Using context for non-preview data * * Components can access context data using `getContext()`: * * @param Component - The React component to wrap * * @example * ```tsx * import { getContext, setContext } from '@optimizely/cms-sdk/react/server'; * * async function MyPage({ params }) { * // Context is initialized by withAppContext * // You can manually set data if needed * setContext({ locale: 'en-US' }); * * const context = getContext(); * return
Locale: {context?.locale}
; * } * * export default withAppContext(MyPage); * ``` */ export declare function withAppContext

(Component: React.ComponentType

): (props: P) => Promise>>;