// With string enums export enum ButtonStatus { HIDDEN = 'HIDDEN', ENABLED = 'ENABLED', DISABLED = 'DISABLED', }; // With union types of string literals type ButtonStatus = 'HIDDEN' | 'ENABLED' | 'DISABLED';
As a general rule, string literal unions are a better default.
String literal unions
Enums
Old doc on this: https://medium.com/@katbusch/typescript-enums-explained-e5f9a101afc9