diff --git a/x-pack/plugins/triggers_actions_ui/common/experimental_features.ts b/x-pack/plugins/triggers_actions_ui/common/experimental_features.ts index 1f055b965115a..07f70b9b329a7 100644 --- a/x-pack/plugins/triggers_actions_ui/common/experimental_features.ts +++ b/x-pack/plugins/triggers_actions_ui/common/experimental_features.ts @@ -24,6 +24,8 @@ export const allowedExperimentalValues = Object.freeze({ isUsingRuleCreateFlyout: false, }); +const deprecatedExperimentalValues = new Set(['ruleFormV2']); + type ExperimentalConfigKeys = Array; type Mutable = { -readonly [P in keyof T]: T[P] }; @@ -56,7 +58,10 @@ export const parseExperimentalConfigValue = (configValue: string[]): Experimenta }; export const isValidExperimentalValue = (value: string): boolean => { - return allowedKeys.includes(value as keyof ExperimentalFeatures); + return ( + allowedKeys.includes(value as keyof ExperimentalFeatures) || + deprecatedExperimentalValues.has(value) + ); }; export const getExperimentalAllowedValues = (): string[] => [...allowedKeys];