{"version":"1.0","type":"rich","title":"Responding to Resize","description":"This example demonstrates how a D3.js v5 SVG visualization can respond to browser resizing. The chart container fills the page using CSS, and the `redraw()` function extracts its `clientWidth` and `clientHeight` to set the SVG’s dimensions. It then draws a dynamic X shape—two green lines with 100-pixel stroke width—that always spans the full viewport. A `window` resize event listener triggers `redraw()` on every size change, ensuring the visualization stays responsive without recalculating scales. The rendering relies on SVG elements and direct attribute updates.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/e5079bd35f05440ba66c15b6df7ffe01?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}