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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve type for configEmoji option #355

Merged
merged 1 commit into from Dec 18, 2022
Merged

Improve type for configEmoji option #355

merged 1 commit into from Dec 18, 2022

Conversation

bmish
Copy link
Owner

@bmish bmish commented Dec 18, 2022

Use a tuple with named elements instead of just a string array. This provides more information about the expected type, and allows the type-checker (when present) to catch issues sooner instead of depending on runtime checks. This is not a breaking change because we already enforced the same checks at runtime.

As a reminder, the way this option is used is for specifying an emoji for each config like this:

{
  configEmoji: [
    ['recommended', '馃敟'],
    ['stylistic', '馃帹'],
  ],
}

@bmish bmish added the bug Something isn't working label Dec 18, 2022
@bmish bmish merged commit 5f884cf into main Dec 18, 2022
@bmish bmish deleted the type-config-emoji branch December 18, 2022 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants