Skip to content

Latest commit

 

History

History
28 lines (23 loc) · 469 Bytes

README.md

File metadata and controls

28 lines (23 loc) · 469 Bytes

togglify-js

Javascript feature toggler

Install

npm install togglify-js

Usage

import Togglify from 'togglify-js';

const featureName = 'poo feature';
const featuresRepository = [
  {
    name: 'poo feature',
    isEnabled: true
  }
];
const toggler = new Togglify(featuresRepository);

const isFeatureEnabled = toggler.isOn(featureName); // Tell if the feature 'poo feature' is enabled or not

Tests

npm run test