Example of Feature Flags
with Unleash library.
- Install dependencies
yarn install
- Run docker services
docker-compose up -d
- Import dumped data
./import
- Run server
yarn start
Unleash provides admin panel by the address http://localhost:4242, where you can define different toggles and strategies.
In this example we have two toggles already saved: featureX
and featureY
, all enabled.
yarn client
launches example of the client, which is checking both feature flags.
featureX
is a simple feature, that can be turned on or off.
featureY
depends on context, it will be true
for staging environment, and false
for production.