Kendo-datepicker throws undefined error when selected

1 Answer 1199 Views
DateInput DatePicker DateTimePicker
Martin
Top achievements
Rank 1
Martin asked on 10 Sep 2021, 02:54 PM

Hello,

I'm working on an angular project and I used kendo-datepicker in several places. A week ago I updated the angular version to the latest one. Before that version 7 was used.

After the updated, there's an issue with the datepicker components. When I select the toggle calendar icon the following error is thrown:

Uncaught TypeError: Cannot read property 'add' of undefined
    at HeaderComponent.ngOnInit (index.js:11822)
    ....

 

And when I select any date, that's the error, which is thrown:

Uncaught TypeError: Cannot read property 'close' of undefined
    at DatePickerComponent._toggle (index.js:6636)

 

I even tried to use the control in the most basic way in a page, where there's nothing more than it. The result is the same

<kendo-datepicker ></kendo-datepicker>


Angular version: 12.1.2
@progress/kendo-angular-dateinputs: 5.2.2
typescript: 4.3.5

Does anybody has any idea why that happens?

Regards

1 Answer, 1 is accepted

Sort by
1
Accepted
Silviya
Telerik team
answered on 13 Sep 2021, 02:06 PM

Hi Martin,

This error could be caused by the RxJS version used in the project. It is worth checking if it is 7.x

That is because the latest RxJS introduced multiple breaking changes. The observed error in question is probably caused by the following breaking change in RxJS 7:

https://github.com/ReactiveX/rxjs/pull/5656

Kendo UI for Angular still cannot provide full support for RxJS 7. It would require changes in the major version of TypeScript and dropping the older versions of the Angular framework. The team plans to release a secondary distribution channel, supporting the latest versions of Angular framework, RxJS, and Typescript. This can be expected around October, and until that time, the developers are required to use RxJS v6.

Feel free to subscribe to the following thread from our public GitHub repo:

https://github.com/telerik/kendo-angular/issues/3314

I hope this information helps.

Regards,
Silviya
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
DateInput DatePicker DateTimePicker
Asked by
Martin
Top achievements
Rank 1
Answers by
Silviya
Telerik team
Share this question
or