I would love to use this lint rule, but its false positive rate is way to high currently. It seems any function within a jsx/tsx file is considered to be a component regardless of whether it is or not.
If possible, I would use the typescript compiler to check if a function can be considered to be of type FunctionComponent. Doing so, you can safely filter out all false positives.
That being said, I have no idea if the typescript compiler API has such a hook
I would love to use this lint rule, but its false positive rate is way to high currently. It seems any function within a jsx/tsx file is considered to be a component regardless of whether it is or not.
If possible, I would use the typescript compiler to check if a function can be considered to be of type
FunctionComponent. Doing so, you can safely filter out all false positives.That being said, I have no idea if the typescript compiler API has such a hook