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

feat(types): add types to support third-party wrapping scenarios #4307

Merged
merged 2 commits into from
May 9, 2024

Conversation

quantizor
Copy link
Contributor

@quantizor quantizor commented May 8, 2024

This PR exposes some new types that are intended to aid in third-party library adoption for scenarios where the library is wrapping styled-components and injecting additional props.

The new types are:

  • LibraryStyled: a higher-order type that takes LibraryProps and merges them in with any downstream component props
  • Styled: the type for the styled() HOC (the same as typeof styled)
  • StyledInstance: the return type for a usage of the styled() HOC

The FastOmit type has also been exposed to make it more convenient to match behaviors.

@quantizor quantizor merged commit c9dddd6 into main May 9, 2024
5 checks passed
@quantizor quantizor deleted the introduce-type-equivalents branch May 9, 2024 17:48
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

1 participant