Skip to content

cy.stats()

cy.stats — Performance > Diagnostics. Cytoscape.js signatures, parameters and return contract.

cy.stats — Performance › Diagnostics

Preview · Performance › Diagnostics

Read in the complete API reference · All API members

// The renderer's frame statistics, or null when headless
cy.stats(): RendererStats | null

The renderer's frame statistics, or null when headless. The snapshot carries the frame timings, cache hit rates and pass counters — note that cpuFrameMs is encode/submit cost only (submission is fire-and-forget), so reconcile fps against gpuFrameMs.

Returns RendererStats | null

a RendererStats snapshot, or null on a headless instance

Example

console.log(cy.stats()); // null

Example graph and handle setup