{"version":"1.0","type":"rich","title":"Responding to Resize","description":"This example demonstrates how a D3.js visualization can respond to browser resizing by drawing a large green X that spans the full width and height of the viewport. The chart container fills the page using CSS, and the `redraw` function reads the container’s `clientWidth` and `clientHeight` to set the SVG’s dimensions. Two `<line>` elements are bound to data and updated on each resize event via `window.addEventListener(\"resize\", redraw)`. The code uses D3 v5 with SVG rendering, showing a minimal pattern for dynamic sizing.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/ec05a4c84f6e4b9db3e761e5a9fa6df4?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}