UNPKG

@optimizely/optimizely-sdk

Version:

JavaScript SDK for Optimizely Feature Experimentation, Optimizely Full Stack (legacy), and Optimizely Rollouts

47 lines (46 loc) 2.56 kB
/** * Copyright 2025, Optimizely * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { Config, Client, StaticConfigManagerConfig, OpaqueConfigManager, PollingConfigManagerConfig, EventDispatcher, OpaqueEventProcessor, BatchEventProcessorOptions, OdpManagerOptions, OpaqueOdpManager, VuidManagerOptions, OpaqueVuidManager, OpaqueLevelPreset, LoggerConfig, OpaqueLogger, ErrorHandler, OpaqueErrorNotifier } from './export_types'; import { DECISION_SOURCES } from './utils/enums'; import { NOTIFICATION_TYPES, DECISION_NOTIFICATION_TYPES } from './notification_center/type'; import { LogLevel } from './logging/logger'; import { OptimizelyDecideOption } from './shared_types'; import { Maybe } from './utils/type'; import { Platform } from './platform_support'; export type Entrypoint = { __platforms: Platform[]; createInstance: (config: Config) => Client; createStaticProjectConfigManager: (config: StaticConfigManagerConfig) => OpaqueConfigManager; createPollingProjectConfigManager: (config: PollingConfigManagerConfig) => OpaqueConfigManager; eventDispatcher: EventDispatcher; getSendBeaconEventDispatcher: () => Maybe<EventDispatcher>; createForwardingEventProcessor: (eventDispatcher?: EventDispatcher) => OpaqueEventProcessor; createBatchEventProcessor: (options?: BatchEventProcessorOptions) => OpaqueEventProcessor; createOdpManager: (options?: OdpManagerOptions) => OpaqueOdpManager; createVuidManager: (options?: VuidManagerOptions) => OpaqueVuidManager; LogLevel: typeof LogLevel; DEBUG: OpaqueLevelPreset; INFO: OpaqueLevelPreset; WARN: OpaqueLevelPreset; ERROR: OpaqueLevelPreset; createLogger: (config: LoggerConfig) => OpaqueLogger; createErrorNotifier: (errorHandler: ErrorHandler) => OpaqueErrorNotifier; DECISION_SOURCES: typeof DECISION_SOURCES; NOTIFICATION_TYPES: typeof NOTIFICATION_TYPES; DECISION_NOTIFICATION_TYPES: typeof DECISION_NOTIFICATION_TYPES; OptimizelyDecideOption: typeof OptimizelyDecideOption; clientEngine: string; };