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 when calling toast functions

See original GitHub issue

When I call toast.error(“test”) i got the following warning on console:

Warning: Unsafe legacy lifecycles will not be called for components using new component APIs.

TransitionGroup uses getDerivedStateFromProps() but also contains the following legacy lifecycles:
  componentWillMount
  componentWillReceiveProps

The above lifecycles should be removed. Learn more about this warning here:
https://fb.me/react-async-component-lifecycle-hooks

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
fkhadracommented, Aug 2, 2018

Hello @heamaral,

Since React 16.3 componentWillMount and componentWillReceiveProps are ‘deprecated’ in favor of getDerivedStateFromProps and getSnapshotBeforeUpdate.

I need to update react-transition-group from 2.2 to 2.4. Those warning only appear during development, so don’t worry for the moment.

The next release is scheduled for this month.

More detail about react lifecycle here

0reactions
develo-peracommented, Oct 11, 2018

react-transition-group package is where this error comes from

Read more comments on GitHub >

github_iconTop Results From Across the Web

Toasts - Bootstrap
Toasts are lightweight notifications designed to mimic the push notifications that have been popularized by mobile and desktop operating systems. They're built ...
Read more >
Toasts overview - Android Developers
A toast provides simple feedback about an operation in a small popup. It only fills the amount of space required for the message...
Read more >
Toast Notifications - Salesforce Lightning Component Library
A component can send a toast notification that pops up to alert users of a success, error, or warning. A toast can also...
Read more >
Find and clear a toast (Toastr) - Stack Overflow
I have a link (Ok) on each toast on clicking that link I need to close only the particular toast not all toast...
Read more >
Lightning Web Component(LWC) Toast Messages - SfdcPoint
We can style toast to provide error, success, warning and information message using mode parameter. We can also configure the visibility of the ......
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