{"version":"1.0","type":"rich","title":"Responding to Resize","description":"This example demonstrates how a D3 v5 SVG visualization can dynamically respond to browser window resizing. It draws a large green X spanning the full viewport, with the chart container filling the page via fixed CSS positioning. The `redraw` function reads the container’s `clientWidth` and `clientHeight` to update the SVG’s width and height attributes, then repositions two `<line>` elements using a data join. A `window` resize event listener triggers `redraw` on every size change, ensuring the graphic always matches the available space.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/d5091bcd6bd049dea62ed7cddf28cf94?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}