Enum flags are a clever optimisation technique that make use of bitwise logic operations paired with enumerated types that sadly see a lack of use in more modern codebases and languages such as JavaScript, in spite of enum
s being otherwise fairly popular in TypeScript.
enum Guild {
Mage,
Rogue,
Warrior …