Source for all GeoJSON boundaries on Earth
npm install boundaries

GeoJSON boundaries for Earth, masterfully formatted and normalized for your consumption.
Total # as of writing this: 40,106
- Use the NPM module to retrieve and access the data (instructions below)
- Use this repo as a submodule and write your own thing to load the data (just a bunch of json files!)
- Link directly to the files on GitHub
Using one of these methods, the boundaries are accessible on any language or platform. Enjoy!
- Neighborhoods
- Zillow
- States/Cities/Counties/Zip Codes
- US Census Bureau (TIGER 2016)
Mostly US boundaries right now (data availability), but would love to add more around the world. Know of more good sources for boundary data? Send a PR!
- id (String)
- Unique ID for this boundary
- type (String)
- state, neighborhood, county, etc.
- name (String)
- Display Name
- area (Object)
- GeoJSON MultiPolygon
- No simplification, original precision
```
npm install boundaries
- listSync()readSync(path)
- Synchronous
- Returns an array of boundary file paths
- list([cb])
- Synchronous
- Returns a object representing the boundary for the given path
- listSync
- Asynchronous form of read(path[, cb])
- Callback is optional, returns a promise
- readSync
- Asynchronous form of
- Callback is optional, returns a promise
Simple example of listing boundaries and reading them synchronously.
#### ES5
`js
var boundaries = require('boundaries');
var fs = require('fs');
var files = boundaries.listSync();
files.forEach(function(filePath) {
var boundary = boundaries.readSync(filePath);
// Do something with it!
});
`
#### ES6
`js
import { listSync, readSync } from 'boundaries'
const files = listSync()
files.forEach((filePath) => {
const boundary = readSync(filePath)
// Do something with it!
})
``
[downloads-image]: http://img.shields.io/npm/dm/boundaries.svg
[npm-url]: https://npmjs.org/package/boundaries
[npm-image]: http://img.shields.io/npm/v/boundaries.svg