JoshuaKGoldberg / JoshuaKGoldberg/TypeStat

Allow preferences for using React.FC or props interfaces

Open
#171 0 comments 0 reactions 0 assignees View on GitHub
area: options area: react status: accepting prs
Dominant language
TypeScript
Stars
2.3k
Forks
47
Avg merge
15h 55m
Merged PRs (30d)
21

Description

Given this React component:

```ts
const MyComponent = ({ greeting, name }) =>
return `${greeting}, ${name}!`;
```

Should the `MyComponentProps` be added as...
* `{ greeting, name }: My ComponentProps`
* `MyComponent: React.FC`

Following #170, there should be a configuration within `incompleteTypes` to allow one or the other. This will necessitate making the `fixes.incompleteTypes` allow a complex object in addition to a boolean.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.