question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code.

See original GitHub issue

Description

I am receiving the following warning when using Animated.View:

Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details.

* Move code with side effects to componentDidMount, and set initial state in the constructor.

Please update the following components: AnimatedComponent

Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details.

* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state

Please update the following components: AnimatedComponent

Package versions

name version
react-native ^0.64.3
react-native-reanimated ~2.3.1
NodeJS 16.13.0
expo ~44.0.0

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
nassif7commented, Jun 30, 2022

I got the same issue. It seems to happen when using the <React.StrictMode> since i removed i stopped seeing this warning

0reactions
rumbogscommented, Jul 18, 2022

Same here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Warning: Using UNSAFE_componentWillMount in strict mode ...
Warning : Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. #623.
Read more >
How can I fix `Using UNSAFE_componentWillMount in strict ...
How can I fix `Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code.`? Ask Question. Asked 2 ......
Read more >
warning: using unsafe_componentwillmount in strict mode is ...
Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. * Move data fetching code or side effects...
Read more >
Lokesh Sanapalli on Twitter: "getting this error from react ...
getting this error from react-helmet package Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code seems like ......
Read more >
How can I fix `Using UNSAFE_componentWillMount in strict ...
Related Query · How can I fix `Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. ·...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found