Skip to content

TypeScript enums #277

@osnoser1

Description

@osnoser1

🔖 Enhancement description

Is there a way to, instead of generating enums, generate types and constants, e.g.

🎤 Pitch

From:

export enum ItemsRunItemOrigin {
  TEMPLATE = 'template',
  CARRYOVER = 'carryover',
  ADHOC = 'adhoc',
}

to

export const ItemsRunItemOrigin = {
  TEMPLATE = 'template',
  CARRYOVER = 'carryover',
  ADHOC = 'adhoc',
} as const;

export type ItemsRunItemOrigin = typeof ItemsRunItemOrigin[keyof typeof ItemsRunItemOrigin];

Thank you very much in advance

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions