If it is possible, does anyone have an example of how to use async pipe in FullCalendar? For example something like this?
<full-calendar [events]="events$ | async"></full-calendar>
CodePudding user response:
You could create a container around your html tag and pass the entire config options object:
<ng-container *ngIf="calendarOptions2$ | async as options">
<full-calendar [options]="options"></full-calendar>
</ng-container>
Working example: https://stackblitz.com/edit/angular-ivy-ht8hof
CodePudding user response:
using the async pipe this way will actually work.
But the problem is that full-calendar is not expected any input named events
The only input it expect is options
so your code should like:
<full-calendar [options]="{
events: events$ | async
}"></full-calendar>
