All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- Updated
@optimizely/optimizely-sdkto version6.xand migrated from the Lite API to the Universal API (createInstance,createStaticProjectConfigManager,createForwardingEventProcessor,createEventDispatcher). - Updated
@fastly/js-computeto version3.xand build directly to WebAssembly, removing the Webpack build step andcore-jspolyfill. - Replaced the
uuidpackage with the nativecrypto.randomUUID()for user ID generation. - Updated the
cookiepackage from0.4.2to2.xand switched to its named v2 API (parseCookie,stringifySetCookie). - Externalized the SDK key: it is now read from a Fastly Config Store (
optimizely) instead of being hardcoded insrc/index.js. - Implemented graceful degradation so the service still responds if Optimizely initialization or a decision fails.
- Improved datafile caching with a module-scope stale fallback layered on the Fastly edge
CacheOverridecache, with a configurable TTL via thedatafile_ttl_secondsConfig Store key. - Added JSDoc documentation throughout the codebase.
- Overhauled the README with a quick start, features, prerequisites, project structure, and troubleshooting.
- New
FastlyRequestHandlerclass implementing the Optimizely SDK request-handler interface over Fastly'sfetchwith named backends andCacheOverride. - New
getOptimizelyClientandgetDatafilehelpers for client management and datafile fetching. - Unit test suite using Vitest (
index.test.js,optimizely_helper.test.js,request_handler.test.js) with Fastly runtime mocks. - Biome configuration (
biome.jsonc) for linting and formatting, andvitest.config.jsfor tests. optimizelyConfig Store setup infastly.tomlfor local development and deployment.
- Removed the
uuidpackage dependency (replaced with the native Web Crypto API). - Removed the Webpack build configuration (
webpack.config.js).
- Added cookie based user id memorization to support sticky bucketing.
- Updated
@optimizely/optimizely-sdkversion to4.9.1.
- First version of Fastly starter kit with datafile caching and event dispatcher.