Releases: Flagsmith/flagsmith-js-client
Releases · Flagsmith/flagsmith-js-client
1.6.1 - Fix react native types
This release fixes an issue with react native types #82
1.6.0 - Use api.flagsmith.com
Prior to this release, API calls from the JS SDK went to https://api.bullet-train.io, now they go to https://api.flagsmith.com
1.5.0 Multiple flagsmith instances
1.5.0
This release allows you to create multiple instances of flagsmith, this may be used when you wish to identify multiple users simultaneously within your app and retain access to getValue, hasFeature etc for each user.
Type:
export function createFlagsmithInstance (): IFlagsmith<br class="Apple-interchange-newline">
Usage:
import { createFlagsmithInstance } from "flagsmith";
const flagsmith = createFlagsmithInstance();
const flagsmithB = createFlagsmithInstance();
// now you can use flagsmith as before but in its own instance
Added traits parameter to identify
As of this release you can now supply traits with the identify call, this combines setTraits and identify into 1 call.
/**
* Identify user, triggers a call to get flags if flagsmith.init has been called
*/
identify:(userId:string, traits?: Record<string, string|number|boolean>,) => Promise<IFlags|undefined>