Open wassimmohamed opened 2 years ago
This workaround worked for me. You can give it a try
const nextSchedulerData = Object.assign(
Object.create(Object.getPrototypeOf(schedulerData)),
schedulerData
);
setSchedulerData(nextSchedulerData);
@tdangkhoa0303 could you post a barebones demo code of the scheduler working in hooks, I have tried repeatedly to get a version of this working with hooks and have been unable.
When I use this library with 17.x version of react gives me error so:
react-dom.development.js:67 Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.
npx react-codemod rename-unsafe-lifecycles
in your project source folder.Please update the following components: EventItem, ResourceEvents
when I click screen everything disappear and this time errors appear. If someone help me about this I would be so glad.
When I use this library with 17.x version of react gives me error so:
react-dom.development.js:67 Warning: componentWillReceiveProps has been renamed, and is not recommended for use. 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
- Rename componentWillReceiveProps to UNSAFEcomponentWillReceiveProps to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE name will work. To rename all deprecated lifecycles to their new names, you can run
npx react-codemod rename-unsafe-lifecycles
in your project source folder.Please update the following components: EventItem, ResourceEvents
when I click screen everything disappear and this time errors appear. If someone help me about this I would be so glad.
Don't know if you are still using this package but I forked the repo and made some changes.
When i use this library with latest react version (17.x) with hooks it is not rerendering. ex, setSchedulerData(schedulerData) is not working while changing the view. But when i use class component it is working fine. ex, this.setState({schedulerData:_schedulerData}) Is there any workaround/ fix?