Imagine I have the following union type:
type Browser = 'Chrome' | 'Firefox'
I am looking to convert this into an array:
const browsers = /* code to change Browser type into ['Chrome', 'Firefox']
The goal is to use it during runtime. Is there a way to achieve this? I attempted using key of
, but unfortunately, that did not work.