Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

199
Visualizações
Angular Syncfusion schedule cannot invoke an object which is possibly 'undefined

I am working on Angular Syncfusion for allowing user to show and book appoinments and following below link https://ej2.syncfusion.com/angular/documentation/schedule/editor-template/#how-to-prevent-the-display-of-editor-and-quick-popups

Below is my code.

<ejs-schedule #scheduleObj   class="schedule" cssClass='schedule-group-custom-work-days' width='100%' height='650px'
[selectedDate]="selectedDate" [workDays]='workWeekDays' (popupOpen)='onPopupOpen($event)' [eventSettings]='eventSettings' showQuickInfo]='showQuickInfo'
[allowResizing]=true ></ejs-schedule>
  @ViewChild('scheduleObj')
  public scheduleObj!: ScheduleComponent;
  public eventSettings: EventSettingsModel = { dataSource: [] };
  selectedTileDate: any;
  public selectedDate: Date = new Date();
  public showQuickInfo: Boolean = window.innerWidth > 1024 ? false : true;


 public onPopupOpen(args: PopupOpenEventArgs): void {
}

But I am getting error Cannot invoke an object which is possibly 'undefined'. I am able to resolve this error by doing below in tsconfig.json

"angularCompilerOptions": {
   ...,
   "strictTemplates": false
}

But then it is disabling the strict check in my whole application. Is there a better way to deal with it?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

We have validated your reported issue and suggest you set “strictNullChecks” to false in the “complierOptions” in the tsconfig.json file like below to overcome the issue.

tsconfig.json

"compilerOptions": {

    .

    .

    .

    .

    .

"strictNullChecks": false,

}

Kindly try the above solution and let us know if you need any assistance.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda