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

Expand generic type names to be more descriptive #155

Merged
merged 1 commit into from Sep 14, 2020

Conversation

zephraph
Copy link
Contributor

@zephraph zephraph commented Sep 12, 2020

This is a quality of life refactor to ease understanding of what types represent what. It expends generic template names like B to be a more descriptive BreakpointKey.

There are a few particular places that deserve special attention which I'll call out in the changes.

Release Notes

This update expands the generic type names to be self descriptive instead of being single characters. While this change predominately only affects internal types the internal BreakpointKey was renamed to BreakpointConstraint. Give that that's not documented as part of our external API we haven't listed this release as a breaking change; however, if you use that import you will need to update your references.

@zephraph zephraph self-assigned this Sep 12, 2020
export { BreakpointKey } from "./Breakpoints"
export { BreakpointConstraint as BreakpointKey } from "./Breakpoints"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is to avoid having breaking changes in the external API

Comment on lines -17 to +20
export enum BreakpointKey {
export enum BreakpointConstraint {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

While this is technically a breaking change for this module's api, it should only affect the internal API.

The external API is preserved via this change.

Copy link
Collaborator

@alloy alloy left a comment

Choose a reason for hiding this comment

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

Nice 👍

@zephraph zephraph changed the title Expand generic names to be more descriptive Expand generic type names to be more descriptive Sep 14, 2020
@zephraph zephraph merged commit 4c51059 into master Sep 14, 2020
@zephraph zephraph deleted the expand-generic-types branch September 14, 2020 17:11
@artsyit
Copy link
Contributor

artsyit commented Sep 14, 2020

🚀 PR was released in v1.2.2 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants