Skip to content

Commit dc28d64

Browse files
authored
Improve predefined variations documentation (#671)
* Improve Predefined Variations documentation * Rename "Predefined Variation" page to "Predefined Variation vs Free-Form Values"
1 parent b820449 commit dc28d64

File tree

2 files changed

+10
-11
lines changed

2 files changed

+10
-11
lines changed

website/docs/advanced/predefined-variations.mdx

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
---
22
id: predefined-variations
3-
title: Predefined Variations
3+
title: Predefined Variations vs Free‑Form Values
44
description: Learn about free-form values and predefined variations in ConfigCat, how they differ, and when to use each approach for managing feature flag values.
55
---
66

77
ConfigCat supports two value-modes for feature flags: _free-form values_ and _predefined variations_. This guide explains the differences between these approaches and helps you choose the right one for your use case.
88

9-
109
## Overview
1110

1211
In ConfigCat, you can configure feature flags to operate in either of these modes:
1312

14-
- **Free-form values** - Allows arbitrary feature flag values. You can set served values to any value.
13+
- **Free-form values** - Allows arbitrary values for non-boolean feature flags. You can set served values of such flags to any value.
1514
- **Predefined variations** - Constrains feature flag values to a set of variations specified beforehand. You can select served values from a dropdown.
1615

1716
<p>
1817
<img src="/docs/assets/predefined-variations/usage_192dpi.png" alt="Clone feature flag" width="1366" height="768" decoding="async" loading="lazy" />
1918
</p>
2019

2120
## Free-form values
21+
2222
Free-form values are the traditional, unrestrictive mode that lets you enter a feature flag's exact value each time you set it.
2323

2424
<p>
@@ -37,8 +37,6 @@ Free-form values are the traditional, unrestrictive mode that lets you enter a f
3737

3838
Free-form values work well when you have simple, one-off configurations where feature flag values are unique and unlikely to be reused. They're ideal when you need quick setup without upfront planning, especially when working with primitive values like booleans or simple strings and numbers. This approach is also suitable when values change frequently or unpredictably.
3939

40-
41-
4240
## Predefined variations
4341

4442
Predefined variations allow you to define a set of reusable values upfront when creating a feature flag. These variations can then be selected from a dropdown when setting up flag rules. Each variation consists of three fields:
@@ -66,24 +64,25 @@ Predefined variations allow you to define a set of reusable values upfront when
6664

6765
Predefined variations are ideal when you have a standard set of values used across multiple rules, especially when consistency is critical for things like color schemes, API endpoints, or configuration objects. They work well when multiple team members need to understand what each value represents and you want to prevent typos or invalid values. This approach is particularly valuable when complex values like JSON objects need to be reused, when you need to provide guidance on when to use specific values, and when values are known upfront and relatively stable.
6866

69-
7067
## Converting between free-form values and predefined variations
7168

7269
ConfigCat provides an easy way to convert feature flags between free-form values and predefined variations.
7370

7471
### Converting to predefined variations
7572

76-
You can convert a feature flag to use predefined variations by clicking the **Convert to use variations** item in the kebab (3 dots) menu of the feature flag.
73+
You can convert a feature flag to use predefined variations by clicking the **Convert to use variations** item in the kebab (3 dots) menu of the feature flag.
74+
7775
When you convert a feature flag from free-form values to predefined variations, ConfigCat automatically collects all currently used values from your existing flag rules. These collected values are presented as suggested variations, but you can modify their display names and hints, or even add new variations.
7876

79-
The conversion doesn't affect your deployed applications.
77+
The conversion doesn't affect your applications deployed to production.
8078

8179
### Converting to free-form values
8280

83-
You can convert a feature flag to use free-form values by clicking the **Convert to use free-form values** item in the kebab (3 dots) menu of the feature flag.
81+
You can convert a feature flag to use free-form values by clicking the **Convert to use free-form values** item in the kebab (3 dots) menu of the feature flag. (For boolean feature flags, the corresponding menu item is **Convert to use ON/OFF toggle**.)
82+
8483
When you convert a feature flag from predefined variations to free-form values, the actual values from variations are extracted and feature flag values are updated to use the values directly. Display names and hints are irreversibly deleted, leaving only the values.
8584

86-
The conversion doesn't affect your deployed applications.
85+
The conversion doesn't affect your applications deployed to production.
8786

8887
## Working with predefined variations
8988

website/src/pages/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ const features = [
2929
links: [
3030
{ url: 'api/reference/configcat-public-management-api', title: 'Public Management API' },
3131
{ url: 'advanced/data-governance', title: 'Data Governance - CDN' },
32-
{ url: 'advanced/predefined-variations', title: 'Predefined Variations' },
32+
{ url: 'advanced/predefined-variations', title: 'Predefined Variations vs Free‑Form Values' },
3333
{ url: 'advanced/variation-id-for-analytics', title: 'Variation ID for analytics' },
3434
{ url: 'advanced/caching', title: 'Polling modes & Caching' },
3535
{

0 commit comments

Comments
 (0)