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

Add FunctionComponent matcher #5

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

krnlde
Copy link

@krnlde krnlde commented Dec 3, 2019

I'd like to use snappify in a hook-based environment where FunctionComponents are key. Unfortunately there is yet no matcher for those. I propose change to also catch FunctionComponents.

TBD: Should SFCs also be supported?

@denisraslov
Copy link
Owner

denisraslov commented Dec 4, 2019

Hi @krnlde!

Thank you for the PR! Yes, I think it's a great idea to add matchers for FunctionComponent, SFC and even FC.
It would be great if you could also add matchers for SFC and FC and some tests to cover the new matchers to this PR (you can find the tests in __tests__/componentReader). I would be happy to merge these changes!

@krnlde
Copy link
Author

krnlde commented Dec 4, 2019

Nice :) Will do!

@krnlde
Copy link
Author

krnlde commented Mar 6, 2020

I added SFC and FC but tbh I don't understand how to write your componentReader tests :D any support on this? Create new files or extend existing ones?

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.

2 participants