You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@optimizely/optimizely-sdk

Package Overview
Dependencies
Maintainers
1
Versions
87
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@optimizely/optimizely-sdk - npm Package Versions

1
57
9

4.0.0-rc.1

Diff
o
optimizely-fullstack
published 4.0.0-rc.1 •

Changelog

Source

[4.0.0-rc.1] - April 17, 2020

New Features

  • ES module entry point for the browser - "module" property of package.json points to dist/optimizely.browser.es.min.js (#445)

Breaking Changes:

  • Dropped support for Node.js version <8 (#456)

Bug fixes

  • Node.js datafile manager uses gzip,deflate compression for requests (#456)
o
optimizely-fullstack
published 4.0.0-alpha.1 •

Changelog

Source

[4.0.0-alpha.1] - March 4, 2020

Breaking Changes:

  • Removed Promise polyfill from browser entry point (417).

  • Changed functionality of JSON schema validation in all entry points (442).

    • Previously, skipJSONValidation flag was used by the user to specify whether the JSON object should be validated.
    • Now, skipJSONValidation has been removed entirely from all entry points. Instead, a user will need to import jsonSchemaValidator from @optimizely/optimizely-sdk/dist/optimizely.json_schema_validator.min.js and pass it to createInstance to perform validation as shown below:
    const optimizelySDK = require('@optimizely/optimizely-sdk');
    const jsonSchemaValidator = require('@optimizely/optimizely-sdk/dist/optimizely.json_schema_validator.min');
    
    // Require JSON schema validation for the datafile
    var optimizelyClientInstance = optimizely.createInstance({
      datafile: datafile,
      jsonSchemaValidator: jsonSchemaValidator,
    });
    
o
optimizely-fullstack
published 3.6.0-alpha.1 •

Changelog

Source

[3.6.0-alpha.1] - March 4, 2020

New Features

  • Changed track() to log a warning instead of an error when the event isn't in the datafile (#418)
o
optimizely-fullstack
published 3.5.0 •

Changelog

Source

[3.5.0] - February 20th, 2020

Bug fixes

  • Fixed default event dispatcher not used in React Native entry point (#383)
  • Fixed errors in getOptimizelyConfig TypeScript type definitions (#406)

New Features

  • Promise returned from close tracks the state of in-flight event dispatcher requests (#404)
o
optimizely-fullstack
published 3.4.1 •

Changelog

Source

[3.4.1] - January 28th, 2020

Bug fixes

  • Added getOptimizelyConfig and related types to TypeScript type definitions(#390).
o
optimizely-fullstack
published 3.4.0 •

Changelog

Source

[3.4.0] - January 21th, 2020

Bug fixes

  • Fixed incorrect payload for decision notification triggered by calling getVariation on a feature test in a mutex group(#375).

New Features

  • Added a new API to get project configuration static data.
    • Call getOptimizelyConfig() to get a snapshot of project configuration static data.
    • It returns an OptimizelyConfig instance which includes a datafile revision number, all experiments, and feature flags mapped by their key values.
    • Added caching for getOptimizelyConfig - OptimizelyConfig object will be cached and reused for the lifetime of the datafile.
    • For details, refer to our documentation page: https://docs.developers.optimizely.com/full-stack/docs/optimizelyconfig-javascript-node.

Removed Features

  • Removed support for 'launched' experiment status
    • Previously, experiments with status 'running' or 'launched' would return non-null variations from activate and getVariation, and generate impression events from activate
    • Now, only 'running' experiments will return non-null variations and generate impressions
o
optimizely-fullstack
published 3.4.0-beta •

Changelog

Source

[3.4.0-beta] - December 18th, 2019

Bug fixes

  • Fixed incorrect payload for decision notification triggered by calling getVariation on a feature test in a mutex group(#375)

New Features

  • Added a new API to get a project configuration static data.
    • Call getOptimizelyConfig() to get a snapshot copy of project configuration static data.
    • It returns an OptimizelyConfig instance which includes a datafile revision number, all experiments, and feature flags mapped by their key values.
    • For details, refer to a documention page: https://docs.developers.optimizely.com/full-stack/docs/optimizelyconfig-javascript-node
o
optimizely-fullstack
published 3.3.2 •

Changelog

Source

[3.3.2] - November 14th, 2019

Bug fixes

  • Fixed error message that was being logged when a user was bucketed into empty space in an experiment or a mutual exclusion group. This is not an error. With the fix, the message indicates that the user was not included in any experiment (#366).
o
optimizely-fullstack
published 3.3.1 •

Changelog

Source

[3.3.1] - October 25th, 2019

Bug fixes

  • Fixed full screen error dialog appearing in local development for React Native apps when using the default logger. We now provide a default logger for React Native that does not call console.error.
o
optimizely-fullstack
published 3.3.0 •

Changelog

Source

[3.3.0] - September 25th, 2019

New Features

  • Added support for event batching via the event processor.
    • Events generated by methods like activate, track, and isFeatureEnabled will be held in a queue until the configured batch size is reached, or the configured flush interval has elapsed. Then, they will be combined into a request and sent to the event dispatcher.
    • To configure event batching, include the eventBatchSize and eventFlushInterval number properties in the object you pass to createInstance.
    • Event batching is enabled by default. eventBatchSize defaults to 10. eventFlushInterval defaults to 30000 in Node and 1000 in browsers.
  • Added localStorage mitigation against lost events in the browser
    • When event requests are dispatched, they are written to localStorage, and when a response is received, they are removed from localStorage.
    • When the SDK is initialized for the first time in the browser, if any requests remain in localStorage, they will be sent, and removed from localStorage when a response is received.
  • Updated the close method to return a Promise representing the process of closing the instance. When close is called, any events waiting to be sent as part of a batched event request will be immediately batched and sent to the event dispatcher.
    • If any such requests were sent to the event dispatcher, close returns a Promise that fulfills after the event dispatcher calls the response callback for each request. Otherwise, close returns an immediately-fulfilled Promise.
    • The Promise returned from close is fulfilled with a result object containing success (boolean) and reason (string, only when success is false) properties. In the result object, success is true if all events in the queue at the time close was called were combined into requests, sent to the event dispatcher, and the event dispatcher called the callbacks for each request. success is false if an unexpected error was encountered during the close process.
  • Added non-typed getFeatureVariable method (#298) as a more idiomatic approach to getting values of feature variables.
    • Typed getFeatureVariable methods will still be available for use.