D3.js version where xExtent and yExtent functionality were added to d3.behavior.zoom.
These limit all actions to ensure the domain of the corresponding scale always stays within the given extent.
For details, see the original pull request.
D3.js is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG, and CSS. D3 emphasizes web standards and combines powerful visualization components with a data-driven approach to DOM manipulation, giving you the full capabilities of modern browsers without tying yourself to a proprietary framework.
Want to learn more? See the wiki.
For examples, see the gallery and mbostock’s bl.ocks.