loop enum in typescript es6 code example Example: typescript iterate over enum for (const key in EnumObject) { console.log(key, EnumObject[key]); }