typescript type of part of enum values code example
Example: typescript type from enum values
enum Weekday {
MONDAY = 'mon',
TUESDAY = 'tue',
WEDNESDAY = 'wed'
}
type WeekdayType = `${Weekday}`;
enum Weekday {
MONDAY = 'mon',
TUESDAY = 'tue',
WEDNESDAY = 'wed'
}
type WeekdayType = `${Weekday}`;