Something missing with header property of scheduler.config

I´m using scheduler since a while, now I need to make it responsive. I saw there is a property header of SchedulerConfigOptions, but when I try to use it I’m getting “Property ‘header’ does not exists on type ‘SchedulerConfigOptions’”.
In my reasearchs I’ve found in type definition it doesn’t exist but in dhtmlxscheduler.js exists.

I’m working with Angular 11 and versions of packages are:
@types/dhtmlxscheduler”: “^4.3.40”
“dhtmlx-scheduler”: “^5.3.11”

What is going wrong?

Hello @Hermes,

It looks like you are using old type definitions for the scheduler.
Currently, we providing type definitions for the scheduler with the scheduler package, in the file: dhtmlxscheduler.d.ts
If you will use it instead of old definitions, the issue should be fixed:

Hello
But if I remove “@types/dhtmlxscheduler”: “^4.3.40” package, the scheduler object is not found.
“error TS2304: Cannot find name ‘scheduler’.”
I’m following the angular reference and https://dhtmlx.com/blog/angular-dhtmlxscheduler-tutorial/
All works fine but the types definition is old…
How must I do in angular 11 to get all working?

Thanks in advance

Hello,

This tutorial is a little bit outdated, and currently, we work on the new one.

In order to make the scheduler work again you have to declare it in the following way:

// scheduler component file

import 'dhtmlx-scheduler'; // import scheduler 


declare let scheduler: any; //  declare it to fix the issue

Kind regards,

It is important to have an updated example of it use in angular, I’ve tested your suggestion before and have the same problem in components that use SchedulerComponent. (TS2304: Cannot find name ‘scheduler’)

Thank you

Hello @Siarhei,
Finally I could make it work and my responsive scheduler it’s ok!

Thank you