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

Fix issue #403 with snake case filenames #404

Merged
merged 3 commits into from
Aug 9, 2022

Conversation

kamaltmo
Copy link
Contributor

Fixes #403 by extending the regex for the isStyledClass function to support look for the patterns -sc-or _sc- anywhere in a class name or sc- at the start of class name. This should allow toHaveStyleRule to function with classNames that contain a filename for a component within them even when that filename is snake case.

Copy link
Contributor

@quantizor quantizor left a comment

Choose a reason for hiding this comment

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

LGTM thanks!

@quantizor quantizor enabled auto-merge (squash) August 9, 2022 13:15
@quantizor quantizor merged commit a620482 into styled-components:main Aug 9, 2022
@kamaltmo kamaltmo deleted the patch-1 branch August 9, 2022 15:15
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.

toHaveStyleRule is not compatible with some displayNames if fileName is used
2 participants