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

change ItemType enum to avoid breaking change #234

Merged
merged 1 commit into from
Nov 30, 2020
Merged

Conversation

winkerVSbecks
Copy link
Collaborator

No description provided.

Comment on lines -15 to +18
// export type ItemType = 'menu' | 'link' | 'bullet-link';

export enum ItemType {
MENU,
LINK,
BULLET_LINK,
MENU = 'menu',
LINK = 'link',
BULLET_LINK = 'bullet-link',
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't totally follow this, just because I'm not familiar w/ enums in TS. Was this previously exporting each of these as, for example, the uppercased MENU vs menu?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

As numbers. MENU = 0, LINK = 1, etc. That's the default behaviour for TS enums

Copy link
Contributor

@kylesuss kylesuss left a comment

Choose a reason for hiding this comment

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

👍

@winkerVSbecks winkerVSbecks merged commit 8455d66 into master Nov 30, 2020
@winkerVSbecks winkerVSbecks added the patch Increment the patch version when merged label Nov 30, 2020
@winkerVSbecks winkerVSbecks deleted the fix-toc-types branch November 30, 2020 19:07
@winkerVSbecks
Copy link
Collaborator Author

🚀 PR was released in v5.4.2 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch Increment the patch version when merged released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants