Latest Post

The Basics of Poker How to Use Toggle Properly

A toggle is a switch that has two outcomes: either it’s on or it’s off. It is used in computer hardware, software, and user interfaces, including web browsers and mobile apps. Toggles help users update preferences, settings, and other kinds of information. Toggles work best when they are clear, direct, and straightforward. Toggles also work best when they are consistent. Users should always know what the current state of a toggle is. Avoid using toggles with multiple labels or multiple outcomes, which confuses the user. Toggles should also be easy to understand – use clear, direct labels and don’t rely on color alone (see WCAG 1.4.1).

When a feature is a toggle it’s important to think about its lifecycle. A toggle may have a very long or short lifecycle depending on its purpose. For example, a visibility toggle can hide content from viewers while allowing the owner to see the hidden content if they want to. Other types of toggles are not as dynamic and have a shorter lifecycle. For example, a Champagne Brunch may be used to expose a new feature to a random cohort of users and will not need to be re-deployed as often as a Canary Release.

Savvy teams view their Feature Toggle inventory as carrying cost and seek to keep the number of toggles low. They also strive to remove toggles when they are no longer needed. Some teams do this by adding a toggle removal task to their backlog whenever they create a new toggle. Other teams put “expiration dates” on their toggles and will fail a test (or even refuse to start an application) if a toggle has expired.