// The model-space rectangle currently visible, as { x1, y1, x2, y2, w, h } — the inverse of the pan/zoom transform applied to the viewport box
cy.extent(): ExtentThe model-space rectangle currently visible, as { x1, y1, x2, y2, w, h } — the inverse of the pan/zoom transform applied to the viewport box.
Returns
Extentthe visible extent in model coordinates
Example
cy.zoom(1); cy.pan({ x: 0, y: 0 });console.log(cy.extent().w); // 800See
Core#renderedExtent for the same box in rendered coordinates