diff --git a/README.md b/README.md index 9710ca5..4039d7d 100644 --- a/README.md +++ b/README.md @@ -11,11 +11,17 @@ A [quadtree](https://en.wikipedia.org/wiki/Quadtree) is a two-dimensional recurs ## Installing -If you use NPM, `npm install d3-quadtree`. Otherwise, download the [latest release](https://github.com/d3/d3-quadtree/releases/latest). +If you use NPM, `npm install d3-quadtree`. Otherwise, download the [latest release](https://github.com/d3/d3-quadtree/releases/latest). The released bundle supports AMD, CommonJS, and vanilla environments. Create a custom build using [Rollup](https://github.com/rollup/rollup) or your preferred bundler. You can also load directly from [d3js.org](https://d3js.org): + +```html + +``` + +In a vanilla environment, a `d3_quadtree` global is exported. [Try d3-quadtree in your browser.](https://tonicdev.com/npm/d3-quadtree) ## API Reference -# quadtree() +# d3_quadtree.quadtree() Creates a new [quadtree factory](#_quadtree) with the default [*x*-accessor](#quadtree_x), [*y*-accessor](#quadtree_y) and [extent](#quadtree_extent). The returned factory function can be used to create any number of quadtrees from data. diff --git a/package.json b/package.json index fa9e76d..2ad3481 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "d3-quadtree", - "version": "0.0.3", + "version": "0.1.0", "description": "Two-dimensional recursive spatial subdivision.", "keywords": [ "d3", @@ -24,7 +24,7 @@ "prepublish": "npm run test && uglifyjs build/d3-quadtree.js -c -m -o build/d3-quadtree.min.js && rm -f build/d3-quadtree.zip && zip -j build/d3-quadtree.zip -- LICENSE README.md build/d3-quadtree.js build/d3-quadtree.min.js" }, "devDependencies": { - "d3-arrays": "~0.3.1", + "d3-array": "~0.6.1", "faucet": "0.0", "rollup": "0.20.5", "tape": "4",