microsoft / microsoft/TypeScript
Revaluate default props behavior in JSX functional components
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 111k
- Forks
- 14.3k
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 132
Description
Regarding the recognition of default initializers as part of type checking on functional components, I believe issues #32402 and #31247 should be reevaluated in the light of #34547 and the potential deprecation of defaultProps, and also on the own merits of both issues.
TypeScript Version: 3.7.5
Search Terms:
defaulProps, FunctionalComponent, JSX, React
Code
View issues #32402 and #31247
Expected behavior:
View issues #32402 and #31247
Actual behavior:
View issues #32402 and #31247
Playground Link:
View issues #32402 and #31247
Related Issues:
Issues #32402 and #31247 =D
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading issues #32402 and #31247, then compare their proposals with issue #34547 and the discussion about deprecating defaultProps. The payload names no source files, tests, or entry points; the work is complete only after the intended JSX functional-component type-checking behavior is agreed and validated.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- compilers, frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100