The ffc-js-client-side-sdk demo for react with jotai
-
Go to https://portal.featureflag.co create your project
-
Create two flags in your environment
-
Open src/app/ffcConfig.ts and fill the option constant with the right value
export const option: IOption = {
secret: "USE_YOUR_ENVIRONMENT_SECRET", // replace with your won secret
anonymous: false,
user: { // you can keep this
id: 'my-user',
userName: 'my user',
email: '',
customizedProperties: [
{
"name": "sex",
"value": "male"
}]
},
devModePassword: 'thisisademo'
}
- Run
npm install
npm run start