Releases: launchdarkly/js-client-sdk
Releases · launchdarkly/js-client-sdk
2.12.5
[2.12.5] - 2019-07-29
Changed:
- The error messages logged upon having an invalid environment/client-side ID have been updated to better clarify what went wrong. (#165)
Fixed:
- The React SDK was incompatible with Internet Explorer 11 due to using
String.startsWith(). (Thanks, cvetanov!) - There was a broken documentation link in the error message logged when initially sending an event without identifying a user. The broken link has been fixed.
2.12.4
[2.12.4] - 2019-07-10
Changed:
- The
useReportproperty, which tells the SDK to use the REPORT method for HTTP requests so that user data will not appear in the URL path, was only actually using REPORT for requesting all flags at once— not for streaming updates, because streaming uses the EventSource API which normally can only use the GET method; so, to avoid exposing user data in the URL for the streaming connection, the SDK had to use a different and slower mechanism (in which all of the flags are reloaded whenever there is a change) ifuseReportwas true. That is still the case by default; but, if you load the specific EventSource polyfill implementationlaunchdarkly-eventsource(v1.1.0 or later), the SDK can now use REPORT for streaming connections.
Fixed:
- The
homepageattribute in thelaunchdarkly-react-client-sdkandlaunchdarkly-react-client-sdk-examplepackages has been updated to the correct value.
2.12.3
[2.12.3] - 2019-07-08
Added:
- The SDK now logs a message at
infolevel when the stream connection is started or stopped. It also logs a message atwarnlevel if it detects that the stream had to be restarted due to a connection failure; however, in browsers that have native support for EventSource, connection restarts may be handled internally by the browser in which case there will be no log message.
Changed:
- When providing precomputed flag values to the SDK via the
bootstrapoption, these values will now be immediately available as soon asinitialize()returns. That was already the behavior in earlier versions of the SDK, but ever since version 2.10.0 the values only became available once the client was officially ready (i.e. thereadyevent had fired or thewaitUntilInitialized()promise had resolved), so they could not be used in non-asynchronous application code. The correct behavior had never been explicitly defined, so this had not been documented as a change. The behavior is now as it was prior to 2.10.0, and is now documented as such. (#162)
Fixed:
- Under some circumstances, the SDK would fail to restart a streaming connection if it had already been dropped and restarted before. This normally would not happen when using a built-in browser implementation of EventSource, but could happen with some EventSource polyfills.
- Fixed a broken link in the project README.
2.12.2
[2.1.2] - 2019-06-28
Fixed:
- The
eventUrlTransformerproperty that was added in 2.12.0 had no effect. It now works.
2.12.1
[2.12.1] - 2019-06-28
Added:
- The SDK now logs a message at
infolevel when the stream connection is started or stopped. It also logs a message atwarnlevel if it detects that the stream had to be restarted due to a connection failure; however, in browsers that have native support for EventSource, connection restarts may be handled internally by the browser in which case there will be no log message.
Fixed:
- Under some circumstances, the SDK would fail to restart a streaming connection if it had already been dropped and restarted before. This normally would not happen when using a built-in browser implementation of EventSource, but could happen with some EventSource polyfills.
- Fixed a broken link in the project README.
2.12.0
[2.12.0] - 2019-06-18
Added:
- Configuration property
eventUrlTransformerallows application code to modify the URL that is sent in analytics events.
Fixed:
- If the SDK receives data from the service that does not have the expected JSON content type, it will now log an appropriate error message, rather than "Error fetching flags: 200".
2.11.0
[2.11.0] - 2019-06-06
Added:
- Added support for hooks to the React SDK.
2.10.4
[2.10.4] - 2019-05-22
Added:
unpkgentry topackage.jsonto specify primary build artifact to simplify the unpkg snippet URL.
Fixed:
- Streaming updates did not work if
useReportwas enabled, or if the SDK was connecting through the LaunchDarkly relay proxy. This bug was introduced in version 2.10.0.
2.10.3
[2.10.3] - 2019-05-08
Changed:
- Changed the package names from
ldclient-js,ldclient-react, andldclient-js-commontolaunchdarkly-js-client-sdk,launchdarkly-react-client-sdk, andlaunchdarkly-js-sdk-common, respectively.
There are no other changes in this release. Substituting ldclient-js, ldclient-react, and ldclient-js-common version 2.10.2 with launchdarkly-js-client-sdk, launchdarkly-react-client-sdk, and launchdarkly-js-sdk-common version 2.10.3 will not affect functionality.
Fixed:
- Fixed some broken links in the package READMEs.
2.10.2
[2.10.2] - 2019-05-01
Fixed:
- Fixed a problem that prevented the Electron and client-side Node SDKs from reporting their own version strings correctly. This fix does not affect the browser JS SDK, so there is no need to upgrade if you are using that.
Note on future releases:
The LaunchDarkly SDK repositories are being renamed for consistency. This repository is now js-client-sdk rather than js-client.
The package names will also change. In the 2.10.2 release, there were packages for ldclient-js, ldclient-react and ldclient-js-common; in all future releases, they will be launchdarkly-js-client-sdk, launchdarkly-react-client-sdk, and launchdarkly-js-sdk-common, respectively.