Domain event emitted when an image is created.
Part of the event-driven architecture for cross-cutting concerns like notifications, logging, and analytics.
const event = new ImageCreatedEvent({ id: "01912c9a-5e8a-7b5c-8a1b-2c3d4e5f6a7b", path: "image.jpg", userId: "user-123", caller: "addImage",});// event.eventType === "image.created"await eventHandler.handle(event); Copy
const event = new ImageCreatedEvent({ id: "01912c9a-5e8a-7b5c-8a1b-2c3d4e5f6a7b", path: "image.jpg", userId: "user-123", caller: "addImage",});// event.eventType === "image.created"await eventHandler.handle(event);
Creates a new ImageCreatedEvent.
Event data containing image details and metadata
The function/method that triggered the event
The image ID
The image storage path
The user who created the image
Readonly
The type of event (e.g., "article.created")
Contextual information about the event
Event-specific data
Domain event emitted when an image is created.
Remarks
Part of the event-driven architecture for cross-cutting concerns like notifications, logging, and analytics.
Example
See