Angular Demo

Live <kal-calendar> below — loaded via script tag. See the integration guide for Angular project setup.

Event Log

Angular Integration Guide
# Install the package
npm install kalendly

# Import styles in angular.json → projects → architect → build → styles
"node_modules/kalendly/dist/styles/calendar.css"
// app.module.ts
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { AppComponent } from './app.component';
import 'kalendly';

@NgModule({
  declarations: [AppComponent],
  imports: [BrowserModule],
  schemas: [CUSTOM_ELEMENTS_SCHEMA],
  bootstrap: [AppComponent],
})
export class AppModule {}
// app.component.ts (standalone)
import { Component, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import 'kalendly';

@Component({
  selector: 'app-root',
  standalone: true,
  schemas: [CUSTOM_ELEMENTS_SCHEMA],
  templateUrl: './app.component.html',
})
export class AppComponent {
  events = [
    { id: 1, name: 'Team Standup', date: new Date() },
  ];

  onDateSelect(e: CustomEvent) {
    console.log('Selected:', e.detail.date);
  }
}
<!-- app.component.html -->
<kal-calendar
  title="My Calendar"
  [events]="events"
  (cal-date-select)="onDateSelect($event)"
  (cal-month-change)="onMonthChange($event)"
></kal-calendar>
// app.component.ts
import { Component } from '@angular/core';
import { CalendarEvent } from 'kalendly/core';

@Component({ ... })
export class AppComponent {
  events: CalendarEvent[] = [];

  onDateSelect(e: CustomEvent) {
    const { date, events } = e.detail;
    console.log('Selected:', date, events);
  }

  onMonthChange(e: CustomEvent) {
    const { year, month } = e.detail;
    console.log('Month:', year, month);
  }
}