defaultProps deprecation warning

Open
#523 5 comments 0 reactions 0 assignees View on GitHub

@snehaljos is already working on this.

Since Jul 31, 2023.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Refactor
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, react
Domain
frontend

Research direction

Start by reading the defaultProps example in src/components/FormEdit.jsx at the referenced line, then search the source for other component defaultProps usages. Replace the reported usages with JavaScript default parameters and confirm the newer React defaultProps warning is no longer produced.

Written by the indexing model from the issue text.

Description

Many components in this library use defaultProps, which causes a warning in newer versions of React. It is expected to replaced with JavaScript default parameters instead. (Detailed explanation)

(Example in source code](https://github.com/formio/react/blob/c966dd1d93d1ee5b5610496e2578ebc9ce153eb6/src/components/FormEdit.jsx#L164C13-L164C13)

Dominant language
TypeScript
Stars
371
Forks
309
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from formio/react

All issues in formio/react

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.