Skip to content

Collection

A shareable, portable bundle of events (a .cdy document is its JSON form). Inert data: a manifest of the plugins its events need + the events themselves. Load it with cal.load() after registering the declared plugins.

optional $schema?: string

Optional JSON Schema URL for editor/AI validation + autocomplete of the .cdy document. Point it at the published schema: "https://calendaryjs.dev/schema/cdy.json". The core ignores it at runtime.


optional collection?: string

Collection name; used as the group id when id is omitted.


events: (EventConfig | Buildable)[]

The events — plain configs (as in a .cdy file) or builders.


optional id?: string

Group id (defaults to collection, else "collection").


optional name?: string

Group display name.


optional plugins?: string[]

Plugin package names the events need — validated on load.


optional version?: string

Collection version (semver-ish, informational).