snappify
snappify copied to clipboard
Add FunctionComponent matcher
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 SFC
s also be supported?
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!
Nice :) Will do!
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?