@turf/simplify 6.5.0 → 7.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -7
- package/dist/es/index.js +0 -0
- package/dist/js/index.js +0 -0
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -7,15 +7,16 @@
|
|
|
7
7
|
Takes a [GeoJSON][1] object and returns a simplified version. Internally uses
|
|
8
8
|
[simplify-js][2] to perform simplification using the Ramer-Douglas-Peucker algorithm.
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
### Parameters
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
- `options.tolerance` **[number][5]** simplification tolerance (optional, default `1`)
|
|
15
|
-
- `options.highQuality` **[boolean][6]** whether or not to spend more time to create a higher-quality simplification with a different algorithm (optional, default `false`)
|
|
16
|
-
- `options.mutate` **[boolean][6]** allows GeoJSON input to be mutated (significant performance increase if true) (optional, default `false`)
|
|
12
|
+
* `geojson` **[GeoJSON][3]** object to be simplified
|
|
13
|
+
* `options` **[Object][4]** Optional parameters (optional, default `{}`)
|
|
17
14
|
|
|
18
|
-
**
|
|
15
|
+
* `options.tolerance` **[number][5]** simplification tolerance (optional, default `1`)
|
|
16
|
+
* `options.highQuality` **[boolean][6]** whether or not to spend more time to create a higher-quality simplification with a different algorithm (optional, default `false`)
|
|
17
|
+
* `options.mutate` **[boolean][6]** allows GeoJSON input to be mutated (significant performance increase if true) (optional, default `false`)
|
|
18
|
+
|
|
19
|
+
### Examples
|
|
19
20
|
|
|
20
21
|
```javascript
|
|
21
22
|
var geojson = turf.polygon([[
|
package/dist/es/index.js
CHANGED
|
File without changes
|
package/dist/js/index.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@turf/simplify",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0-alpha.0",
|
|
4
4
|
"description": "turf simplify module",
|
|
5
5
|
"author": "Turf Authors",
|
|
6
6
|
"contributors": [
|
|
@@ -49,10 +49,10 @@
|
|
|
49
49
|
"docs": "node ../../scripts/generate-readmes",
|
|
50
50
|
"test": "npm-run-all test:*",
|
|
51
51
|
"test:tape": "node -r esm test.js",
|
|
52
|
-
"test:types": "tsc --esModuleInterop --noEmit types.ts"
|
|
52
|
+
"test:types": "tsc --esModuleInterop --noEmit --strict types.ts"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@turf/truncate": "^
|
|
55
|
+
"@turf/truncate": "^7.0.0-alpha.0",
|
|
56
56
|
"benchmark": "*",
|
|
57
57
|
"load-json-file": "*",
|
|
58
58
|
"npm-run-all": "*",
|
|
@@ -61,10 +61,10 @@
|
|
|
61
61
|
"write-json-file": "*"
|
|
62
62
|
},
|
|
63
63
|
"dependencies": {
|
|
64
|
-
"@turf/clean-coords": "^
|
|
65
|
-
"@turf/clone": "^
|
|
66
|
-
"@turf/helpers": "^
|
|
67
|
-
"@turf/meta": "^
|
|
64
|
+
"@turf/clean-coords": "^7.0.0-alpha.0",
|
|
65
|
+
"@turf/clone": "^7.0.0-alpha.0",
|
|
66
|
+
"@turf/helpers": "^7.0.0-alpha.0",
|
|
67
|
+
"@turf/meta": "^7.0.0-alpha.0"
|
|
68
68
|
},
|
|
69
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "0edc4c491b999e5ace770a61e1cf549f7c004189"
|
|
70
70
|
}
|