spfx project doctor - add checks for React and React DOM
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.5k
- Forks
- 413
- Avg merge
- 5d 6h
- Merged PRs (30d)
- 21
Description
In many cases developers forget to add dependencies to React and ReactDOM while creating React component.
Most often this situation could be noticed for SPFx command sets and application customizers as those libraries are not added there by default.
The proposal is to add extra check to spfx project doctor that will:
- check if there are
tsxfiles - check if there are imports from
reactorreact-dom
If at least one of two checks is positive - propose to install correct dependencies for react, react-dom and dev dependencies for @types/react and @types/react-dom.
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 at the spfx project doctor entry point and trace its existing project checks and dependency suggestions. Confirm the TSX and React/ReactDOM import detection cases and that the proposed runtime and type dependencies match the issue; the command should identify React usage and offer the requested packages.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100