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

[Widgets refactor] typing use enums #1067

Merged
merged 1 commit into from
Nov 1, 2023
Merged

[Widgets refactor] typing use enums #1067

merged 1 commit into from
Nov 1, 2023

Conversation

mishig25
Copy link
Collaborator

@mishig25 mishig25 commented Oct 30, 2023

Nit: use enums when makes sense here

Copy link
Contributor

@SBrandeis SBrandeis left a comment

Choose a reason for hiding this comment

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

What's the benefit of typing it this way?

@mishig25
Copy link
Collaborator Author

mishig25 commented Oct 30, 2023

No benefit. I thought it would be stylistically consistent with

export enum InferenceDisplayability {
/**
* Yes
*/
Yes = "Yes",
/**
* And then, all the possible reasons why it's no:
*/
ExplicitOptOut = "ExplicitOptOut",
CustomCode = "CustomCode",
LibraryNotDetected = "LibraryNotDetected",
PipelineNotDetected = "PipelineNotDetected",
PipelineLibraryPairNotSupported = "PipelineLibraryPairNotSupported",
}

@mishig25 mishig25 merged commit 99bb9b4 into main Nov 1, 2023
2 checks passed
@mishig25 mishig25 deleted the use_enums branch November 1, 2023 15:00
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.

2 participants