processing / processing/p5.js-web-editor
Unwanted warning componentWillMount has been renamed, and is not recommended for use.
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.7k
- Forks
- 1.7k
- Avg merge
- 3d 4h
- Merged PRs (30d)
- 8
Description
p5.js version
No response
What is your operating system?
None
Web browser and version
No response
Actual Behavior
I ran npm run test and the tests all passed ✅ …but the console threw up this React unsafe lifecycle warning ⚠️.
It’s complaining about componentWillMount being deprecated and suggesting migration to UNSAFE_componentWillMount or moving logic into componentDidMount. The warning points to SideEffect(NullComponent) as the culprit.
So while the tests are green, the warning is a reminder that we’ve got some legacy lifecycle methods lurking in the codebase that could cause trouble down the line.
Expected Behavior
It should pass all the Test cases without throwing any warning specially not unsafe one.
Steps to reproduce
Steps:
- clone this repository
- run
npm install - run
npm run test
Snippet:
// Paste your code here :)
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
Run npm install and npm run test to reproduce the warning, then trace the reported SideEffect(NullComponent) component and its use of componentWillMount. Update the relevant lifecycle usage so the test suite remains green without the unsafe lifecycle warning.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend, testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100