View Source SimpleFeatureFlags (Simple Feature Flags v0.1.1)

This module includes functions for checking whether a feature is enabled (enabled?/1), and for introspecting configuration (current_configuration_to_string/0).

Summary

Functions

Return the current configuration as a human-friendly string.

Is feature x enabled in the current deployment environment?

Functions

Link to this function

current_configuration_to_string()

View Source

Return the current configuration as a human-friendly string.

Examples

iex> SimpleFeatureFlags.current_configuration_to_string()
"Current Deployment Environment: :test\nPossible Deployment Environments: [:test, :localhost, :staging, :production]\nFeatures:\n - test_feature_1, enabled in [:all]\n - test_feature_2, enabled in :all\n - test_feature_3, enabled in [:test]\n - test_feature_4, enabled in [:staging, :test, :production]\n - test_feature_5, enabled in [:staging, :production]\n - test_feature_6, enabled in []\n"

Is feature x enabled in the current deployment environment?

Examples

iex> SimpleFeatureFlags.enabled?(:test_feature_1)
true