Open AlirezaGhadyani opened 2 years ago
I have the exact same error. The app is working fine, Owl Carousel is working fine except for this error message in the console:
react-dom.development.js:67 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: ReactOwlCarousel
@laurenchen0631 This is the same as Issue 110 which was opened on 29 Nov 2021. Should we expect a fix for this in one of the next releases?
Hi Guys here i have the seme issue. Please update the way that you manage the state. Any plan for this update ?
how to fixed this warning anybody can help?
Hi. I found "UNSAFE_componentWillReceiveProps" only in react-owl-carousel/src/OwlCarousel.tsx. It seems to be used in lines 32-34...
public UNSAFE_componentWillReceiveProps() {
this.destory();
}
...and 80-84:
public destory() {
if (!this.$ele) throw new Error('OwlCarousel is not created');
this.$ele.trigger('destroy.owl.carousel');
}
Is this necessary? Seems like those lines were useless. Maybe if it will be removed or replaced correctly, an error message will disappear. Can anybody help?
Is there a fix to this yet?
I am using react-owl-carousel-dotlab. They don't have this issue and there is no need to update the code, just install this package and import it.
I am using react-owl-carousel-dotlab. They don't have this issue and there is no need to update the code, just install this package and import it.
Page Not Found....
I am having the same issue right now
I am having the same issue right now
im using the 2.3.3v and i have this issue
index.js:1 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.
Please update the following components: ReactOwlCarousel![Capture](https://user-images.githubusercontent.com/81858771/146538911-1cb53936-cc4e-488f-ae1d-df0f07b86c99.PNG)