String enums

Sometimes you need a collection of strings collected under a common key. TypeScript does have enum support but it is number based. However TypeScript does have string literal types and you can use those as string based enums quite easily by combining with union types.

results matching ""

    No results matching ""