Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(rest): remove
const enum
s in favour of regular enums (#9243)
* fix(rest): remove `const enum`s in favour of regular enums The motivation is that `const enum` produces ambient const enums when compiling which in turn causes issues with TypeScript 5.x when `verbatimModuleSyntax` is enabled. Furthermore, the generally accepted best practice is to avoid `const enum`s when writing libraries. Can back this up with statements from TS maintainers if needed, I know they made them, I just can't be bothered to find the GitHub links lmao. @vladfrangu will probably be able to find those links much easier than me as it was also the motivation to remove `const enum`'s from discord-api-types * refactor(rest): restore `const enum` for internal enum --------- Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
- Loading branch information
229ad07
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
discord-js – ./apps/website
discordjs.dev
discord-js-git-main-discordjs.vercel.app
discord-js-number-one.vercel.app
www.discordjs.dev
discord-js-discordjs.vercel.app
229ad07
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
discord-js-guide – ./apps/guide
discord-js-guide.vercel.app
guide.discordjs.dev
next.discordjs.guide
discord-js-guide-git-main-discordjs.vercel.app
discord-js-guide-discordjs.vercel.app