Hello. I am trying to implement Bryntum Calendar in our NextJS project. Everything seems to work fine except one thing. I am using "timeline" mode as shown in this example - https://bryntum.com/products/calendar/examples/calendar-scheduler/ .
Lets say the calendar lies on a route /calendar. If I want to navigate to another route, the calendar throws some runtime error which causes crash of the NextJS app.
I found out that this behaviour only happens when there is features prop (https://bryntum.com/products/calendar/docs/api/Scheduler/view/Scheduler#config-features) in timeline widget settings (event if it is an empty object). From the call stack I assume, that something is going wrong when the Scheduler instance in timeline widget is being destroyed.
Call Stack:
Uncaught TypeError: this.timeAxis[aYh(...)] is not a function
at eval (calendar.module.js:983:367780)
at Array.some (<anonymous>)
at get hasVisibleEvents (calendar.module.js:983:367740)
at Scheduler.refresh (calendar.module.js:983:386562)
at ResourceTimeRanges.doDisable (calendar.module.js:983:1026009)
at ResourceTimeRanges.updateDisabled (calendar.module.js:930:223498)
at ResourceTimeRanges.set (calendar.module.js:930:55405)
at ResourceTimeRanges.set (calendar.module.js:930:56183)
at ResourceTimeRanges.setConfig (calendar.module.js:930:68305)
at ResourceTimeRanges.configure (calendar.module.js:930:67242)
at ResourceTimeRanges.construct (calendar.module.js:930:63612)
at ResourceTimeRanges.construct (calendar.module.js:930:86604)
at ResourceTimeRanges.construct (calendar.module.js:930:214585)
at ResourceTimeRanges.construct (calendar.module.js:930:220182)
at f.<computed>.construct (calendar.module.js:983:51137)
at new _Base (calendar.module.js:930:63257)
at new b (calendar.module.js:930:85718)
at new b (calendar.module.js:930:213496)
at new InstancePlugin (calendar.module.js:930:218630)
at new b (calendar.module.js:983:825253)
at new ResourceTimeRangesBase (calendar.module.js:983:1025296)
at new ResourceTimeRanges (calendar.module.js:983:1283755)
at Object.get (calendar.module.js:983:51241)
at Object.values (<anonymous>)
at Scheduler.doDestroy (calendar.module.js:983:159764)
at Scheduler.doDestroy (calendar.module.js:983:348791)
at Scheduler.doDestroy (calendar.module.js:983:318445)
at Scheduler.doDestroy (calendar.module.js:983:364197)
at Scheduler.doDestroy (calendar.module.js:983:825103)
at Scheduler.doDestroy (calendar.module.js:983:774595)
at Scheduler.doDestroy (calendar.module.js:983:805605)
at Scheduler.doDestroy (calendar.module.js:930:286893)
at Scheduler.doDestroy [as $oldDestructor] (calendar.module.js:983:807814)
at Object.destructorInterceptor (calendar.module.js:930:93224)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval (calendar.module.js:930:43558)
at Scheduler.eval [as doDestroy] (calendar.module.js:930:43558)
at Scheduler.destroy (calendar.module.js:930:63956)
Any ideas how to prevent this runtime error?