Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EventsSDK: Remove Enums #125

Merged
merged 2 commits into from
Jan 31, 2024
Merged

EventsSDK: Remove Enums #125

merged 2 commits into from
Jan 31, 2024

Conversation

ejaffee01
Copy link
Contributor

We learned that using enums in TypeScript is bad practice in favor of types. This updates Environment, Region, and VersionLabel files to use types instead of enums. In addition, we delete the EnumOrString type and update setupRequestUrl and relevant tests.

J=FUS-6202
R=abenno, mtian
TEST=auto

@ejaffee01 ejaffee01 self-assigned this Jan 25, 2024
Copy link
Collaborator

@mtian725 mtian725 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the removal of the EnumOrString type an issue for existing users? Are there even existing users to worry about?

@ejaffee01
Copy link
Contributor Author

Is the removal of the EnumOrString type an issue for existing users? Are there even existing users to worry about?

I don't think so. I think all existing users would be using the sdk from the script tag, which would point them to the older version still using EnumOrString.

src/Region.ts Outdated Show resolved Hide resolved
@mtian725
Copy link
Collaborator

Other than the playwright tests failing, LGTM

@ejaffee01 ejaffee01 merged commit 8b14741 into main Jan 31, 2024
12 checks passed
@ejaffee01 ejaffee01 deleted the union branch January 31, 2024 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants