Package-level declarations

Types

Link copied to clipboard
@Serializable
data class EnableRequest(val eventTypes: List<String>)

Request object containing input parameters for the PerformanceTimelineDomain.enable command.

Link copied to clipboard
@Serializable
object EnableResponse

A dummy response object for the PerformanceTimelineDomain.enable command. This command doesn't return any result at the moment, but this could happen in the future, or could have happened in the past. For forwards and backwards compatibility of the command method, we still declare this class even without properties.

Link copied to clipboard
@Serializable
data class LargestContentfulPaint(val renderTime: TimeSinceEpoch, val loadTime: TimeSinceEpoch, val size: Double, val elementId: String? = null, val url: String? = null, val nodeId: BackendNodeId? = null)

See https://github.com/WICG/LargestContentfulPaint and largest_contentful_paint.idl

Link copied to clipboard
@Serializable
data class LayoutShift(val value: Double, val hadRecentInput: Boolean, val lastInputTime: TimeSinceEpoch, val sources: List<LayoutShiftAttribution>)

See https://wicg.github.io/layout-instability/#sec-layout-shift and layout_shift.idl

Link copied to clipboard
@Serializable
data class LayoutShiftAttribution(val previousRect: Rect, val currentRect: Rect, val nodeId: BackendNodeId? = null)
Link copied to clipboard

Reporting of performance timeline events, as specified in https://w3c.github.io/performance-timeline/#dom-performanceobserver.

Link copied to clipboard
@Serializable
data class TimelineEvent(val frameId: FrameId, val type: String, val name: String, val time: TimeSinceEpoch, val duration: Double? = null, val lcpDetails: LargestContentfulPaint? = null, val layoutShiftDetails: LayoutShift? = null)