Latest Post

Lessons to Learn From Poker What Is a Toggle?

Togle

Toggle is a simple user-interface component that allows users to update settings, preferences, and other types of information. When used properly toggles can minimize scrolling, provide clear visibility of state, and deliver immediate results. When using toggles make sure that they are clearly labeled and use a consistent visual design pattern. Also, be careful about using low contrast colors and consider societal and cultural implications when determining on/off states.

Toggles can be used to perform a variety of different functions in a software system, including things like multivariate or A/B testing. For this type of toggling we generally employ a Toggle Router which sends each user down one or another codepath based upon their cohort, with the toggling decision being made at runtime and changing at least once per release.

Many teams have a policy of adding a toggle removal task to the backlog for every new toggle that is introduced. This helps to keep the number of feature flags in a system manageable. Some teams even put “expiration dates” on their toggles so that they are removed automatically as soon as they are no longer needed.

Managing toggle configuration can become cumbersome at scale with some approaches relying on static files which require manual re-deployment of a service in order to re-configure the toggle. This is not ideal, especially when it comes to things like Ops Toggles where the ability to re-configure a toggle at runtime becomes critical. For this reason many organizations move to a more dynamic configuration management approach which utilizes some form of existing application DB or other form of runtime in-memory re-configuration.