Last active
May 3, 2017 21:08
-
-
Save fouad-j/6b81ce890a3f8bc36300f3355f3527d1 to your computer and use it in GitHub Desktop.
example_angular_toggle_service_es6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module('app').service('toggleService', function() { | |
const TOGGLE_LIST = ['TOGGLE_NAME_1', 'TOGGLE_NAME_2', 'TOGGLE_NAME_3']; | |
this.isEnable = toggleName => TOGGLE_LIST.includes(toggleName); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment