Skip to content

False positives for all functions inside of .tsx/.jsx files that are not react components #1

Description

@mrmeku

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions