In the “Use String as Enum Key” article, we use the keyof typeof keywords to create a union of an enum’s keys. enum Editor { VIM = 'Neovim', EMACS = 'Emacs', VSCODE = 'Visual Studio Code' }; type EditorKey = keyof typeof Editor; // Editor = "VIM" | "EMACS" | "VSCODE" It might not be immediately clear why and how this keywords combination works. In this article, let’s take a closer look. As we alre