# turf-grid

> turf grid module

Latest version **1.0.1** (published 2015-02-06) · MIT license · 0 weekly downloads

## Install

```sh
npm install turf-grid
pnpm add turf-grid
yarn add turf-grid
bun add turf-grid
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2015-02-06 |
| First published | 2014-05-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | morganherlocker |
| Maintainers | morganherlocker, mourner, jvrousseau, jseppi, cspanring, cwmma, lyzidiamond, tmcw |
| Keywords | turf, grid, points, geojson |

## Links

- npm: https://www.npmjs.com/package/turf-grid
- Repository: https://github.com/Turfjs/turf-grid
- Issues: https://github.com/Turfjs/turf-grid/issues
- npm.io page: https://npm.io/package/turf-grid

## Dependencies (1)

- [turf-point](https://npm.io/package/turf-point.md) ^2.0.0

## Alternatives

- [@lexical/table](https://npm.io/package/@lexical/table.md) — 3.0M weekly downloads
- [mantine-datatable](https://npm.io/package/mantine-datatable.md) — 98.2K weekly downloads
- [react-native-collapsible-tab-view](https://npm.io/package/react-native-collapsible-tab-view.md) — 70.6K weekly downloads
- [@handsontable/vue3](https://npm.io/package/@handsontable/vue3.md) — 16.1K weekly downloads
- [vuewordcloud](https://npm.io/package/vuewordcloud.md) — 7.2K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2015-02-06
- 1.0.0 — 2014-12-12
- 0.1.0 — 2014-07-21
- 0.0.2 — 2014-06-02
- 0.0.1 — 2014-05-13

## README

# turf-grid

[![build status](https://secure.travis-ci.org/Turfjs/turf-grid.png)](http://travis-ci.org/Turfjs/turf-grid)

turf grid module


### `turf.grid(extent, depth)`

Takes a bounding box and a cell depth and returns a FeatureCollection of Point features in a grid.


### Parameters

| parameter | type           | description                              |
| --------- | -------------- | ---------------------------------------- |
| `extent`  | Array.<number> | extent in [minX, minY, maxX, maxY] order |
| `depth`   | Number         | how many cells to output                 |


### Example

```js
var extent = [-70.823364, -33.553984, -70.473175, -33.302986];
var depth = 10;

var grid = turf.grid(extent, depth);

//=grid
```

## Installation

Requires [nodejs](http://nodejs.org/).

```sh
$ npm install turf-grid
```

## Tests

```sh
$ npm test
```

---
_Source: https://npm.io/package/turf-grid · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
