jquense / react-big-calendar

gcal/outlook like calendar component
http://jquense.github.io/react-big-calendar/examples/index.html
MIT License
7.88k stars 2.23k forks source link

Uncaught TypeError: Cannot read properties of undefined (reading 'formats') #2174

Open alansaji123 opened 2 years ago

alansaji123 commented 2 years ago

Check that this is really a bug

Reproduction link

localhost:3000

Bug description

at mergeWithDefaults (react-big-calendar.esm.js:323:1) at Calendar.getContext (react-big-calendar.esm.js:4805:1) at new Calendar (react-big-calendar.esm.js:4763:1) at constructClassInstance (react-dom.development.js:12709:1) at updateClassComponent (react-dom.development.js:17425:1) at beginWork (react-dom.development.js:19073:1) at HTMLUnknownElement.callCallback (react-dom.development.js:3945:1) at Object.invokeGuardedCallbackDev (react-dom.development.js:3994:1) at invokeGuardedCallback (react-dom.development.js:4056:1) at beginWork$1 (react-dom.development.js:23964:1) mergeWithDefaults @ react-big-calendar.esm.js:323 getContext @ react-big-calendar.esm.js:4805 Calendar @ react-big-calendar.esm.js:4763 constructClassInstance @ react-dom.development.js:12709 updateClassComponent @ react-dom.development.js:17425 beginWork @ react-dom.development.js:19073 callCallback @ react-dom.development.js:3945 invokeGuardedCallbackDev @ react-dom.development.js:3994 invokeGuardedCallback @ react-dom.development.js:4056 beginWork$1 @ react-dom.development.js:23964 performUnitOfWork @ react-dom.development.js:22776 workLoopSync @ react-dom.development.js:22707 renderRootSync @ react-dom.development.js:22670 performSyncWorkOnRoot @ react-dom.development.js:22293 (anonymous) @ react-dom.development.js:11327 unstable_runWithPriority @ scheduler.development.js:468 runWithPriority$1 @ react-dom.development.js:11276 flushSyncCallbackQueueImpl @ react-dom.development.js:11322 workLoop @ scheduler.development.js:417 flushWork @ scheduler.development.js:390 performWorkUntilDeadline @ scheduler.development.js:157

Expected Behavior

No response

Actual Behavior

No response

react-big-calendar version

0.40.1

React version

17.0.2

Platform/Target and Browser Versions

macOS Monterey ( 12.3.1 )

Validations

Would you like to open a PR for this bug?

cutterbl commented 2 years ago

You have not provided a valid link, reproducing your issue. Please fork this codesandbox and recreate the issue, sharing your link to the reproduction in a new comment to this thread.