add immoweb ui
This commit is contained in:
parent
7e8c79d3d1
commit
151da16c27
266 changed files with 264879 additions and 0 deletions
20
immoweb/node_modules/@turf/bbox/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/bbox/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
55
immoweb/node_modules/@turf/bbox/README.md
generated
vendored
Normal file
55
immoweb/node_modules/@turf/bbox/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
# @turf/bbox
|
||||
|
||||
# bbox
|
||||
|
||||
Takes a set of features, calculates the bbox of all input features, and returns a bounding box.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `geojson` **([Feature](http://geojson.org/geojson-spec.html#feature-objects) \| [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects))** input features
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var pt1 = turf.point([114.175329, 22.2524])
|
||||
var pt2 = turf.point([114.170007, 22.267969])
|
||||
var pt3 = turf.point([114.200649, 22.274641])
|
||||
var pt4 = turf.point([114.200649, 22.274641])
|
||||
var pt5 = turf.point([114.186744, 22.265745])
|
||||
var features = turf.featureCollection([pt1, pt2, pt3, pt4, pt5])
|
||||
|
||||
var bbox = turf.bbox(features);
|
||||
|
||||
var bboxPolygon = turf.bboxPolygon(bbox);
|
||||
|
||||
//=bbox
|
||||
|
||||
//=bboxPolygon
|
||||
```
|
||||
|
||||
Returns **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>** bbox extent in [minX, minY, maxX, maxY] order
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/bbox
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
12
immoweb/node_modules/@turf/bbox/index.d.ts
generated
vendored
Normal file
12
immoweb/node_modules/@turf/bbox/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Feature = GeoJSON.Feature<any>;
|
||||
type Features = GeoJSON.FeatureCollection<any>;
|
||||
type BBox = [number, number, number, number];
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#bbox
|
||||
*/
|
||||
declare function bbox(features: Feature | Features): BBox;
|
||||
declare namespace bbox { }
|
||||
export = bbox;
|
||||
35
immoweb/node_modules/@turf/bbox/index.js
generated
vendored
Normal file
35
immoweb/node_modules/@turf/bbox/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
var each = require('@turf/meta').coordEach;
|
||||
|
||||
/**
|
||||
* Takes a set of features, calculates the bbox of all input features, and returns a bounding box.
|
||||
*
|
||||
* @name bbox
|
||||
* @param {(Feature|FeatureCollection)} geojson input features
|
||||
* @returns {Array<number>} bbox extent in [minX, minY, maxX, maxY] order
|
||||
* @addToMap features, bboxPolygon
|
||||
* @example
|
||||
* var pt1 = turf.point([114.175329, 22.2524])
|
||||
* var pt2 = turf.point([114.170007, 22.267969])
|
||||
* var pt3 = turf.point([114.200649, 22.274641])
|
||||
* var pt4 = turf.point([114.200649, 22.274641])
|
||||
* var pt5 = turf.point([114.186744, 22.265745])
|
||||
* var features = turf.featureCollection([pt1, pt2, pt3, pt4, pt5])
|
||||
*
|
||||
* var bbox = turf.bbox(features);
|
||||
*
|
||||
* var bboxPolygon = turf.bboxPolygon(bbox);
|
||||
*
|
||||
* //=bbox
|
||||
*
|
||||
* //=bboxPolygon
|
||||
*/
|
||||
module.exports = function (geojson) {
|
||||
var bbox = [Infinity, Infinity, -Infinity, -Infinity];
|
||||
each(geojson, function (coord) {
|
||||
if (bbox[0] > coord[0]) bbox[0] = coord[0];
|
||||
if (bbox[1] > coord[1]) bbox[1] = coord[1];
|
||||
if (bbox[2] < coord[0]) bbox[2] = coord[0];
|
||||
if (bbox[3] < coord[1]) bbox[3] = coord[1];
|
||||
});
|
||||
return bbox;
|
||||
};
|
||||
68
immoweb/node_modules/@turf/bbox/package.json
generated
vendored
Normal file
68
immoweb/node_modules/@turf/bbox/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
{
|
||||
"_from": "@turf/bbox@^3.14.0",
|
||||
"_id": "@turf/bbox@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-zuXzlt3nisqc7eBeESLbGLxQRjU=",
|
||||
"_location": "/@turf/bbox",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/bbox@^3.14.0",
|
||||
"name": "@turf/bbox",
|
||||
"escapedName": "@turf%2fbbox",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.14.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.14.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@turf/center"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/bbox/-/bbox-3.14.0.tgz",
|
||||
"_shasum": "cee5f396dde78aca9cede05e1122db18bc504635",
|
||||
"_spec": "@turf/bbox@^3.14.0",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/@turf/center",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"@turf/meta": "^3.14.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "turf bbox module",
|
||||
"devDependencies": {
|
||||
"benchmark": "^1.0.0",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"turf",
|
||||
"extent",
|
||||
"bbox",
|
||||
"polygon",
|
||||
"featurecollection",
|
||||
"geojson"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/bbox",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/center/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/center/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
143
immoweb/node_modules/@turf/center/README.md
generated
vendored
Normal file
143
immoweb/node_modules/@turf/center/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,143 @@
|
|||
# @turf/center
|
||||
|
||||
# center
|
||||
|
||||
Takes a [Feature](http://geojson.org/geojson-spec.html#feature-objects) or [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects) and returns the absolute center point of all features.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **([Feature](http://geojson.org/geojson-spec.html#feature-objects) \| [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects))** input features
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.522259, 35.4691]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.502754, 35.463455]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.508269, 35.463245]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.516809, 35.465779]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.515372, 35.467072]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.509363, 35.463053]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.511123, 35.466601]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.518547, 35.469327]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.519706, 35.469659]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.517839, 35.466998]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.508678, 35.464942]
|
||||
}
|
||||
}, {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-97.514914, 35.463453]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
var centerPt = turf.center(features);
|
||||
centerPt.properties['marker-size'] = 'large';
|
||||
centerPt.properties['marker-color'] = '#000';
|
||||
|
||||
var resultFeatures = features.features.concat(centerPt);
|
||||
var result = {
|
||||
"type": "FeatureCollection",
|
||||
"features": resultFeatures
|
||||
};
|
||||
|
||||
//=result
|
||||
```
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** a Point feature at the absolute center point of all input features
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/center
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
12
immoweb/node_modules/@turf/center/index.d.ts
generated
vendored
Normal file
12
immoweb/node_modules/@turf/center/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Feature = GeoJSON.Feature<any>;
|
||||
type Features = GeoJSON.FeatureCollection<any>;
|
||||
type Point = GeoJSON.Feature<GeoJSON.Point>;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#center
|
||||
*/
|
||||
declare function center(features: Feature | Features): Point;
|
||||
declare namespace center { }
|
||||
export = center;
|
||||
121
immoweb/node_modules/@turf/center/index.js
generated
vendored
Normal file
121
immoweb/node_modules/@turf/center/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,121 @@
|
|||
var bbox = require('@turf/bbox'),
|
||||
point = require('@turf/helpers').point;
|
||||
|
||||
/**
|
||||
* Takes a {@link Feature} or {@link FeatureCollection} and returns the absolute center point of all features.
|
||||
*
|
||||
* @name center
|
||||
* @param {(Feature|FeatureCollection)} layer input features
|
||||
* @return {Feature<Point>} a Point feature at the absolute center point of all input features
|
||||
* @addToMap features, centerPt
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.522259, 35.4691]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.502754, 35.463455]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.508269, 35.463245]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.516809, 35.465779]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.515372, 35.467072]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.509363, 35.463053]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.511123, 35.466601]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.518547, 35.469327]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.519706, 35.469659]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.517839, 35.466998]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.508678, 35.464942]
|
||||
* }
|
||||
* }, {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-97.514914, 35.463453]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
*
|
||||
* var centerPt = turf.center(features);
|
||||
* centerPt.properties['marker-size'] = 'large';
|
||||
* centerPt.properties['marker-color'] = '#000';
|
||||
*
|
||||
* var resultFeatures = features.features.concat(centerPt);
|
||||
* var result = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": resultFeatures
|
||||
* };
|
||||
*
|
||||
* //=result
|
||||
*/
|
||||
|
||||
module.exports = function (layer) {
|
||||
var ext = bbox(layer);
|
||||
var x = (ext[0] + ext[2]) / 2;
|
||||
var y = (ext[1] + ext[3]) / 2;
|
||||
return point([x, y]);
|
||||
};
|
||||
69
immoweb/node_modules/@turf/center/package.json
generated
vendored
Normal file
69
immoweb/node_modules/@turf/center/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
{
|
||||
"_from": "@turf/center@^3.10.3",
|
||||
"_id": "@turf/center@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-EIOspPE308SYiVV0DH1EDEXMnsw=",
|
||||
"_location": "/@turf/center",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/center@^3.10.3",
|
||||
"name": "@turf/center",
|
||||
"escapedName": "@turf%2fcenter",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.10.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.10.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/hexgrid-heatmap"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/center/-/center-3.14.0.tgz",
|
||||
"_shasum": "1083aca4f137d3c4988955740c7d440c45cc9ecc",
|
||||
"_spec": "@turf/center@^3.10.3",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/hexgrid-heatmap",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"@turf/bbox": "^3.14.0",
|
||||
"@turf/helpers": "^3.13.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "turf center module",
|
||||
"devDependencies": {
|
||||
"benchmark": "^1.0.0",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"centroid",
|
||||
"geojson",
|
||||
"gis",
|
||||
"geospatial",
|
||||
"geo",
|
||||
"turf"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/center",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/destination/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/destination/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
67
immoweb/node_modules/@turf/destination/README.md
generated
vendored
Normal file
67
immoweb/node_modules/@turf/destination/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
# @turf/destination
|
||||
|
||||
# destination
|
||||
|
||||
Takes a [Point](http://geojson.org/geojson-spec.html#point) and calculates the location of a destination point given a distance in degrees, radians, miles, or kilometers; and bearing in degrees. This uses the [Haversine formula](http://en.wikipedia.org/wiki/Haversine_formula) to account for global curvature.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `from` **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** starting point
|
||||
- `distance` **[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** distance from the starting point
|
||||
- `bearing` **[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** ranging from -180 to 180
|
||||
- `units` **\[[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)]** miles, kilometers, degrees, or radians (optional, default `kilometers`)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var point = {
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"marker-color": "#0f0"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-75.343, 39.984]
|
||||
}
|
||||
};
|
||||
var distance = 50;
|
||||
var bearing = 90;
|
||||
var units = 'miles';
|
||||
|
||||
var destination = turf.destination(point, distance, bearing, units);
|
||||
destination.properties['marker-color'] = '#f00';
|
||||
|
||||
var result = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [point, destination]
|
||||
};
|
||||
|
||||
//=result
|
||||
```
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** destination point
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/destination
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
10
immoweb/node_modules/@turf/destination/index.d.ts
generated
vendored
Normal file
10
immoweb/node_modules/@turf/destination/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Point = GeoJSON.Feature<GeoJSON.Point>;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#destination
|
||||
*/
|
||||
declare function destination(from: Point, distance: number, bearing: number, units?: string): Point;
|
||||
declare namespace destination { }
|
||||
export = destination;
|
||||
59
immoweb/node_modules/@turf/destination/index.js
generated
vendored
Normal file
59
immoweb/node_modules/@turf/destination/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
//http://en.wikipedia.org/wiki/Haversine_formula
|
||||
//http://www.movable-type.co.uk/scripts/latlong.html
|
||||
var getCoord = require('@turf/invariant').getCoord;
|
||||
var helpers = require('@turf/helpers');
|
||||
var point = helpers.point;
|
||||
var distanceToRadians = helpers.distanceToRadians;
|
||||
|
||||
/**
|
||||
* Takes a {@link Point} and calculates the location of a destination point given a distance in degrees, radians, miles, or kilometers; and bearing in degrees. This uses the [Haversine formula](http://en.wikipedia.org/wiki/Haversine_formula) to account for global curvature.
|
||||
*
|
||||
* @name destination
|
||||
* @param {Feature<Point>} from starting point
|
||||
* @param {number} distance distance from the starting point
|
||||
* @param {number} bearing ranging from -180 to 180
|
||||
* @param {string} [units=kilometers] miles, kilometers, degrees, or radians
|
||||
* @returns {Feature<Point>} destination point
|
||||
* @example
|
||||
* var point = {
|
||||
* "type": "Feature",
|
||||
* "properties": {
|
||||
* "marker-color": "#0f0"
|
||||
* },
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-75.343, 39.984]
|
||||
* }
|
||||
* };
|
||||
* var distance = 50;
|
||||
* var bearing = 90;
|
||||
* var units = 'miles';
|
||||
*
|
||||
* var destination = turf.destination(point, distance, bearing, units);
|
||||
* destination.properties['marker-color'] = '#f00';
|
||||
*
|
||||
* var result = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [point, destination]
|
||||
* };
|
||||
*
|
||||
* //=result
|
||||
*/
|
||||
module.exports = function (from, distance, bearing, units) {
|
||||
var degrees2radians = Math.PI / 180;
|
||||
var radians2degrees = 180 / Math.PI;
|
||||
var coordinates1 = getCoord(from);
|
||||
var longitude1 = degrees2radians * coordinates1[0];
|
||||
var latitude1 = degrees2radians * coordinates1[1];
|
||||
var bearing_rad = degrees2radians * bearing;
|
||||
|
||||
var radians = distanceToRadians(distance, units);
|
||||
|
||||
var latitude2 = Math.asin(Math.sin(latitude1) * Math.cos(radians) +
|
||||
Math.cos(latitude1) * Math.sin(radians) * Math.cos(bearing_rad));
|
||||
var longitude2 = longitude1 + Math.atan2(Math.sin(bearing_rad) *
|
||||
Math.sin(radians) * Math.cos(latitude1),
|
||||
Math.cos(radians) - Math.sin(latitude1) * Math.sin(latitude2));
|
||||
|
||||
return point([radians2degrees * longitude2, radians2degrees * latitude2]);
|
||||
};
|
||||
70
immoweb/node_modules/@turf/destination/package.json
generated
vendored
Normal file
70
immoweb/node_modules/@turf/destination/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,70 @@
|
|||
{
|
||||
"_from": "@turf/destination@^3.10.3",
|
||||
"_id": "@turf/destination@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-7J5lxBnZlzO8rrA/ObSPQtVKw2w=",
|
||||
"_location": "/@turf/destination",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/destination@^3.10.3",
|
||||
"name": "@turf/destination",
|
||||
"escapedName": "@turf%2fdestination",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.10.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.10.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/hexgrid-heatmap"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/destination/-/destination-3.14.0.tgz",
|
||||
"_shasum": "ec9e65c419d99733bcaeb03f39b48f42d54ac36c",
|
||||
"_spec": "@turf/destination@^3.10.3",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/hexgrid-heatmap",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"@turf/helpers": "^3.13.0",
|
||||
"@turf/invariant": "^3.13.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "turf destination module",
|
||||
"devDependencies": {
|
||||
"@turf/distance": "^3.14.0",
|
||||
"benchmark": "^1.0.0",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"turf",
|
||||
"distance",
|
||||
"destination",
|
||||
"bearing",
|
||||
"miles",
|
||||
"km"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/destination",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/distance/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/distance/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
74
immoweb/node_modules/@turf/distance/README.md
generated
vendored
Normal file
74
immoweb/node_modules/@turf/distance/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,74 @@
|
|||
# @turf/distance
|
||||
|
||||
# distance
|
||||
|
||||
Calculates the distance between two [points](http://geojson.org/geojson-spec.html#point) in degrees, radians,
|
||||
miles, or kilometers. This uses the
|
||||
[Haversine formula](http://en.wikipedia.org/wiki/Haversine_formula)
|
||||
to account for global curvature.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `from` **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** origin point
|
||||
- `to` **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** destination point
|
||||
- `units` **\[[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)]** can be degrees, radians, miles, or kilometers (optional, default `kilometers`)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var from = {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-75.343, 39.984]
|
||||
}
|
||||
};
|
||||
var to = {
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [-75.534, 39.123]
|
||||
}
|
||||
};
|
||||
var units = "miles";
|
||||
|
||||
var points = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [from, to]
|
||||
};
|
||||
|
||||
//=points
|
||||
|
||||
var distance = turf.distance(from, to, units);
|
||||
|
||||
//=distance
|
||||
```
|
||||
|
||||
Returns **[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** distance between the two points
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/distance
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
10
immoweb/node_modules/@turf/distance/index.d.ts
generated
vendored
Normal file
10
immoweb/node_modules/@turf/distance/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Point = GeoJSON.Feature<GeoJSON.Point>;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#distance
|
||||
*/
|
||||
declare function distance(from: Point, to: Point, units?: string): number;
|
||||
declare namespace distance { }
|
||||
export = distance;
|
||||
60
immoweb/node_modules/@turf/distance/index.js
generated
vendored
Normal file
60
immoweb/node_modules/@turf/distance/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
var getCoord = require('@turf/invariant').getCoord;
|
||||
var radiansToDistance = require('@turf/helpers').radiansToDistance;
|
||||
//http://en.wikipedia.org/wiki/Haversine_formula
|
||||
//http://www.movable-type.co.uk/scripts/latlong.html
|
||||
|
||||
/**
|
||||
* Calculates the distance between two {@link Point|points} in degrees, radians,
|
||||
* miles, or kilometers. This uses the
|
||||
* [Haversine formula](http://en.wikipedia.org/wiki/Haversine_formula)
|
||||
* to account for global curvature.
|
||||
*
|
||||
* @name distance
|
||||
* @param {Feature<Point>} from origin point
|
||||
* @param {Feature<Point>} to destination point
|
||||
* @param {string} [units=kilometers] can be degrees, radians, miles, or kilometers
|
||||
* @returns {number} distance between the two points
|
||||
* @example
|
||||
* var from = {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-75.343, 39.984]
|
||||
* }
|
||||
* };
|
||||
* var to = {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [-75.534, 39.123]
|
||||
* }
|
||||
* };
|
||||
* var units = "miles";
|
||||
*
|
||||
* var points = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [from, to]
|
||||
* };
|
||||
*
|
||||
* //=points
|
||||
*
|
||||
* var distance = turf.distance(from, to, units);
|
||||
*
|
||||
* //=distance
|
||||
*/
|
||||
module.exports = function (from, to, units) {
|
||||
var degrees2radians = Math.PI / 180;
|
||||
var coordinates1 = getCoord(from);
|
||||
var coordinates2 = getCoord(to);
|
||||
var dLat = degrees2radians * (coordinates2[1] - coordinates1[1]);
|
||||
var dLon = degrees2radians * (coordinates2[0] - coordinates1[0]);
|
||||
var lat1 = degrees2radians * coordinates1[1];
|
||||
var lat2 = degrees2radians * coordinates2[1];
|
||||
|
||||
var a = Math.pow(Math.sin(dLat / 2), 2) +
|
||||
Math.pow(Math.sin(dLon / 2), 2) * Math.cos(lat1) * Math.cos(lat2);
|
||||
|
||||
return radiansToDistance(2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a)), units);
|
||||
};
|
||||
68
immoweb/node_modules/@turf/distance/package.json
generated
vendored
Normal file
68
immoweb/node_modules/@turf/distance/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
{
|
||||
"_from": "@turf/distance@^3.10.3",
|
||||
"_id": "@turf/distance@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-cbDG8mXSO7MAQZjm2jL4KWT0L4s=",
|
||||
"_location": "/@turf/distance",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/distance@^3.10.3",
|
||||
"name": "@turf/distance",
|
||||
"escapedName": "@turf%2fdistance",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.10.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.10.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@turf/hex-grid",
|
||||
"/hexgrid-heatmap"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/distance/-/distance-3.14.0.tgz",
|
||||
"_shasum": "71b0c6f265d23bb3004198e6da32f82964f42f8b",
|
||||
"_spec": "@turf/distance@^3.10.3",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/hexgrid-heatmap",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"@turf/helpers": "^3.13.0",
|
||||
"@turf/invariant": "^3.13.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "turf distance module",
|
||||
"devDependencies": {
|
||||
"benchmark": "^1.0.0",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"turf",
|
||||
"distance",
|
||||
"miles",
|
||||
"km"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/distance",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
3
immoweb/node_modules/@turf/helpers/CHANGELOG.md
generated
vendored
Normal file
3
immoweb/node_modules/@turf/helpers/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
# 2.0.0
|
||||
|
||||
* Only accept `[x, y]` arrays, not as arguments
|
||||
20
immoweb/node_modules/@turf/helpers/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/helpers/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
255
immoweb/node_modules/@turf/helpers/README.md
generated
vendored
Normal file
255
immoweb/node_modules/@turf/helpers/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,255 @@
|
|||
# @turf/helpers
|
||||
|
||||
# feature
|
||||
|
||||
Wraps a GeoJSON [Geometry](http://geojson.org/geojson-spec.html#geometry) in a GeoJSON [Feature](http://geojson.org/geojson-spec.html#feature-objects).
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `geometry` **[Geometry](http://geojson.org/geojson-spec.html#geometry)** input geometry
|
||||
- `properties` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var geometry = {
|
||||
"type": "Point",
|
||||
"coordinates": [
|
||||
67.5,
|
||||
32.84267363195431
|
||||
]
|
||||
}
|
||||
|
||||
var feature = turf.feature(geometry);
|
||||
|
||||
//=feature
|
||||
```
|
||||
|
||||
Returns **[FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects)** a FeatureCollection of input features
|
||||
|
||||
# point
|
||||
|
||||
Takes coordinates and properties (optional) and returns a new [Point](http://geojson.org/geojson-spec.html#point) feature.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>** longitude, latitude position (each in decimal degrees)
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object that is used as the [Feature](http://geojson.org/geojson-spec.html#feature-objects)'s
|
||||
properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var pt1 = turf.point([-75.343, 39.984]);
|
||||
|
||||
//=pt1
|
||||
```
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** a Point feature
|
||||
|
||||
# polygon
|
||||
|
||||
Takes an array of LinearRings and optionally an [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) with properties and returns a [Polygon](http://geojson.org/geojson-spec.html#polygon) feature.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>>** an array of LinearRings
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** a properties object
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var polygon = turf.polygon([[
|
||||
[-2.275543, 53.464547],
|
||||
[-2.275543, 53.489271],
|
||||
[-2.215118, 53.489271],
|
||||
[-2.215118, 53.464547],
|
||||
[-2.275543, 53.464547]
|
||||
]], { name: 'poly1', population: 400});
|
||||
|
||||
//=polygon
|
||||
```
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** throw an error if a LinearRing of the polygon has too few positions
|
||||
or if a LinearRing of the Polygon does not have matching Positions at the
|
||||
beginning & end.
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Polygon](http://geojson.org/geojson-spec.html#polygon)>** a Polygon feature
|
||||
|
||||
# lineString
|
||||
|
||||
Creates a [LineString](http://geojson.org/geojson-spec.html#linestring) based on a
|
||||
coordinate array. Properties can be added optionally.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>** an array of Positions
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object of key-value pairs to add as properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var linestring1 = turf.lineString([
|
||||
[-21.964416, 64.148203],
|
||||
[-21.956176, 64.141316],
|
||||
[-21.93901, 64.135924],
|
||||
[-21.927337, 64.136673]
|
||||
]);
|
||||
var linestring2 = turf.lineString([
|
||||
[-21.929054, 64.127985],
|
||||
[-21.912918, 64.134726],
|
||||
[-21.916007, 64.141016],
|
||||
[-21.930084, 64.14446]
|
||||
], {name: 'line 1', distance: 145});
|
||||
|
||||
//=linestring1
|
||||
|
||||
//=linestring2
|
||||
```
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if no coordinates are passed
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[LineString](http://geojson.org/geojson-spec.html#linestring)>** a LineString feature
|
||||
|
||||
# featureCollection
|
||||
|
||||
Takes one or more [Features](http://geojson.org/geojson-spec.html#feature-objects) and creates a [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects).
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `features` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Feature](http://geojson.org/geojson-spec.html#feature-objects)>** input features
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = [
|
||||
turf.point([-75.343, 39.984], {name: 'Location A'}),
|
||||
turf.point([-75.833, 39.284], {name: 'Location B'}),
|
||||
turf.point([-75.534, 39.123], {name: 'Location C'})
|
||||
];
|
||||
|
||||
var fc = turf.featureCollection(features);
|
||||
|
||||
//=fc
|
||||
```
|
||||
|
||||
Returns **[FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects)** a FeatureCollection of input features
|
||||
|
||||
# multiLineString
|
||||
|
||||
Creates a [Feature<MultiLineString>](Feature<MultiLineString>) based on a
|
||||
coordinate array. Properties can be added optionally.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>>** an array of LineStrings
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object of key-value pairs to add as properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var multiLine = turf.multiLineString([[[0,0],[10,10]]]);
|
||||
|
||||
//=multiLine
|
||||
```
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if no coordinates are passed
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[MultiLineString](http://geojson.org/geojson-spec.html#multilinestring)>** a MultiLineString feature
|
||||
|
||||
# multiPoint
|
||||
|
||||
Creates a [Feature<MultiPoint>](Feature<MultiPoint>) based on a
|
||||
coordinate array. Properties can be added optionally.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>** an array of Positions
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object of key-value pairs to add as properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var multiPt = turf.multiPoint([[0,0],[10,10]]);
|
||||
|
||||
//=multiPt
|
||||
```
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if no coordinates are passed
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[MultiPoint](http://geojson.org/geojson-spec.html#multipoint)>** a MultiPoint feature
|
||||
|
||||
# multiPolygon
|
||||
|
||||
Creates a [Feature<MultiPolygon>](Feature<MultiPolygon>) based on a
|
||||
coordinate array. Properties can be added optionally.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `coordinates` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>>>** an array of Polygons
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object of key-value pairs to add as properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var multiPoly = turf.multiPolygon([[[[0,0],[0,10],[10,10],[10,0],[0,0]]]]);
|
||||
|
||||
//=multiPoly
|
||||
```
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if no coordinates are passed
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[MultiPolygon](http://geojson.org/geojson-spec.html#multipolygon)>** a multipolygon feature
|
||||
|
||||
# geometryCollection
|
||||
|
||||
Creates a [Feature<GeometryCollection>](Feature<GeometryCollection>) based on a
|
||||
coordinate array. Properties can be added optionally.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `geometries` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<{Geometry}>** an array of GeoJSON Geometries
|
||||
- `properties` **\[[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)]** an Object of key-value pairs to add as properties
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var pt = {
|
||||
"type": "Point",
|
||||
"coordinates": [100, 0]
|
||||
};
|
||||
var line = {
|
||||
"type": "LineString",
|
||||
"coordinates": [ [101, 0], [102, 1] ]
|
||||
};
|
||||
var collection = turf.geometryCollection([pt, line]);
|
||||
|
||||
//=collection
|
||||
```
|
||||
|
||||
Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[GeometryCollection](http://geojson.org/geojson-spec.html#geometrycollection)>** a GeoJSON GeometryCollection Feature
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/helpers
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
89
immoweb/node_modules/@turf/helpers/index.d.ts
generated
vendored
Normal file
89
immoweb/node_modules/@turf/helpers/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,89 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
export type Points = GeoJSON.FeatureCollection<GeoJSON.Point>;
|
||||
export type Point = GeoJSON.Feature<GeoJSON.Point>;
|
||||
export type MultiPoints = GeoJSON.FeatureCollection<GeoJSON.MultiPoint>;
|
||||
export type MultiPoint = GeoJSON.Feature<GeoJSON.MultiPoint>;
|
||||
export type LineStrings = GeoJSON.FeatureCollection<GeoJSON.LineString>;
|
||||
export type LineString = GeoJSON.Feature<GeoJSON.LineString>;
|
||||
export type MultiLineStrings = GeoJSON.FeatureCollection<GeoJSON.MultiLineString>;
|
||||
export type MultiLineString = GeoJSON.Feature<GeoJSON.MultiLineString>;
|
||||
export type Polygons = GeoJSON.FeatureCollection<GeoJSON.Polygon>;
|
||||
export type Polygon = GeoJSON.Feature<GeoJSON.Polygon>;
|
||||
export type MultiPolygons = GeoJSON.FeatureCollection<GeoJSON.MultiPolygon>;
|
||||
export type MultiPolygon = GeoJSON.Feature<GeoJSON.MultiPolygon>;
|
||||
export type Features = GeoJSON.FeatureCollection<any>;
|
||||
export type Feature = GeoJSON.Feature<any>;
|
||||
export type Position = GeoJSON.Position;
|
||||
export type LineStringFeatures = LineString | LineStrings | MultiLineString | MultiLineStrings | GeoJSON.LineString | GeoJSON.MultiLineString
|
||||
export type PolygonFeatures = Polygon | Polygons | MultiPolygon | MultiPolygons | GeoJSON.Polygon | GeoJSON.MultiPolygon
|
||||
export type Units = "miles" | "nauticalmiles" | "degrees" | "radians" | "inches" | "yards" | "meters" | "metres" | "kilometers" | "kilometres";
|
||||
export type BBox = [number, number, number, number];
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#feature
|
||||
*/
|
||||
export function feature(geometry: GeoJSON.GeometryObject, properties?: any): Feature;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#point
|
||||
*/
|
||||
export function point(coordinates: Position, properties?: any): Point;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#polygon
|
||||
*/
|
||||
export function polygon(coordinates: Position[][], properties?: any): Polygon;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#linestring
|
||||
*/
|
||||
export function lineString(coordinates: Position[], properties?: any): LineString;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#featurecollection
|
||||
*/
|
||||
export const featureCollection: {
|
||||
(features: Array<Point>): Points;
|
||||
(features: Array<LineString>): LineStrings;
|
||||
(features: Array<Polygon>): Polygons;
|
||||
(features: Array<MultiPoint>): MultiPoints;
|
||||
(features: Array<MultiLineString>): MultiLineStrings;
|
||||
(features: Array<MultiPolygon>): MultiPolygons;
|
||||
(features: Array<Feature>): Features;
|
||||
};
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#multilinestring
|
||||
*/
|
||||
export function multiLineString(coordinates: Position[][], properties?: any): MultiLineString;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#multipoint
|
||||
*/
|
||||
export function multiPoint(coordinates: Position[], properties?: any): MultiPoint;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#multipolygon
|
||||
*/
|
||||
export function multiPolygon(coordinates: Position[][][], properties?: any): MultiPolygon;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#geometrycollection
|
||||
*/
|
||||
export function geometryCollection(geometries: Array<GeoJSON.GeometryObject>, properties?: any): GeoJSON.GeometryCollection;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function radiansToDistance(radians: number, units?: Units): number
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function distanceToRadians(distance: number, units?: Units): number
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function distanceToDegrees(distance: number, units?: Units): number
|
||||
324
immoweb/node_modules/@turf/helpers/index.js
generated
vendored
Normal file
324
immoweb/node_modules/@turf/helpers/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,324 @@
|
|||
/**
|
||||
* Wraps a GeoJSON {@link Geometry} in a GeoJSON {@link Feature}.
|
||||
*
|
||||
* @name feature
|
||||
* @param {Geometry} geometry input geometry
|
||||
* @param {Object} properties properties
|
||||
* @returns {FeatureCollection} a FeatureCollection of input features
|
||||
* @example
|
||||
* var geometry = {
|
||||
* "type": "Point",
|
||||
* "coordinates": [
|
||||
* 67.5,
|
||||
* 32.84267363195431
|
||||
* ]
|
||||
* }
|
||||
*
|
||||
* var feature = turf.feature(geometry);
|
||||
*
|
||||
* //=feature
|
||||
*/
|
||||
function feature(geometry, properties) {
|
||||
if (!geometry) throw new Error('No geometry passed');
|
||||
|
||||
return {
|
||||
type: 'Feature',
|
||||
properties: properties || {},
|
||||
geometry: geometry
|
||||
};
|
||||
}
|
||||
module.exports.feature = feature;
|
||||
|
||||
/**
|
||||
* Takes coordinates and properties (optional) and returns a new {@link Point} feature.
|
||||
*
|
||||
* @name point
|
||||
* @param {Array<number>} coordinates longitude, latitude position (each in decimal degrees)
|
||||
* @param {Object=} properties an Object that is used as the {@link Feature}'s
|
||||
* properties
|
||||
* @returns {Feature<Point>} a Point feature
|
||||
* @example
|
||||
* var pt1 = turf.point([-75.343, 39.984]);
|
||||
*
|
||||
* //=pt1
|
||||
*/
|
||||
module.exports.point = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
if (coordinates.length === undefined) throw new Error('Coordinates must be an array');
|
||||
if (coordinates.length < 2) throw new Error('Coordinates must be at least 2 numbers long');
|
||||
if (typeof coordinates[0] !== 'number' || typeof coordinates[1] !== 'number') throw new Error('Coordinates must numbers');
|
||||
|
||||
return feature({
|
||||
type: 'Point',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
/**
|
||||
* Takes an array of LinearRings and optionally an {@link Object} with properties and returns a {@link Polygon} feature.
|
||||
*
|
||||
* @name polygon
|
||||
* @param {Array<Array<Array<number>>>} coordinates an array of LinearRings
|
||||
* @param {Object=} properties a properties object
|
||||
* @returns {Feature<Polygon>} a Polygon feature
|
||||
* @throws {Error} throw an error if a LinearRing of the polygon has too few positions
|
||||
* or if a LinearRing of the Polygon does not have matching Positions at the
|
||||
* beginning & end.
|
||||
* @example
|
||||
* var polygon = turf.polygon([[
|
||||
* [-2.275543, 53.464547],
|
||||
* [-2.275543, 53.489271],
|
||||
* [-2.215118, 53.489271],
|
||||
* [-2.215118, 53.464547],
|
||||
* [-2.275543, 53.464547]
|
||||
* ]], { name: 'poly1', population: 400});
|
||||
*
|
||||
* //=polygon
|
||||
*/
|
||||
module.exports.polygon = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
|
||||
for (var i = 0; i < coordinates.length; i++) {
|
||||
var ring = coordinates[i];
|
||||
if (ring.length < 4) {
|
||||
throw new Error('Each LinearRing of a Polygon must have 4 or more Positions.');
|
||||
}
|
||||
for (var j = 0; j < ring[ring.length - 1].length; j++) {
|
||||
if (ring[ring.length - 1][j] !== ring[0][j]) {
|
||||
throw new Error('First and last Position are not equivalent.');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return feature({
|
||||
type: 'Polygon',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a {@link LineString} based on a
|
||||
* coordinate array. Properties can be added optionally.
|
||||
*
|
||||
* @name lineString
|
||||
* @param {Array<Array<number>>} coordinates an array of Positions
|
||||
* @param {Object=} properties an Object of key-value pairs to add as properties
|
||||
* @returns {Feature<LineString>} a LineString feature
|
||||
* @throws {Error} if no coordinates are passed
|
||||
* @example
|
||||
* var linestring1 = turf.lineString([
|
||||
* [-21.964416, 64.148203],
|
||||
* [-21.956176, 64.141316],
|
||||
* [-21.93901, 64.135924],
|
||||
* [-21.927337, 64.136673]
|
||||
* ]);
|
||||
* var linestring2 = turf.lineString([
|
||||
* [-21.929054, 64.127985],
|
||||
* [-21.912918, 64.134726],
|
||||
* [-21.916007, 64.141016],
|
||||
* [-21.930084, 64.14446]
|
||||
* ], {name: 'line 1', distance: 145});
|
||||
*
|
||||
* //=linestring1
|
||||
*
|
||||
* //=linestring2
|
||||
*/
|
||||
module.exports.lineString = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
|
||||
return feature({
|
||||
type: 'LineString',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
/**
|
||||
* Takes one or more {@link Feature|Features} and creates a {@link FeatureCollection}.
|
||||
*
|
||||
* @name featureCollection
|
||||
* @param {Feature[]} features input features
|
||||
* @returns {FeatureCollection} a FeatureCollection of input features
|
||||
* @example
|
||||
* var features = [
|
||||
* turf.point([-75.343, 39.984], {name: 'Location A'}),
|
||||
* turf.point([-75.833, 39.284], {name: 'Location B'}),
|
||||
* turf.point([-75.534, 39.123], {name: 'Location C'})
|
||||
* ];
|
||||
*
|
||||
* var fc = turf.featureCollection(features);
|
||||
*
|
||||
* //=fc
|
||||
*/
|
||||
module.exports.featureCollection = function (features) {
|
||||
if (!features) throw new Error('No features passed');
|
||||
|
||||
return {
|
||||
type: 'FeatureCollection',
|
||||
features: features
|
||||
};
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a {@link Feature<MultiLineString>} based on a
|
||||
* coordinate array. Properties can be added optionally.
|
||||
*
|
||||
* @name multiLineString
|
||||
* @param {Array<Array<Array<number>>>} coordinates an array of LineStrings
|
||||
* @param {Object=} properties an Object of key-value pairs to add as properties
|
||||
* @returns {Feature<MultiLineString>} a MultiLineString feature
|
||||
* @throws {Error} if no coordinates are passed
|
||||
* @example
|
||||
* var multiLine = turf.multiLineString([[[0,0],[10,10]]]);
|
||||
*
|
||||
* //=multiLine
|
||||
*
|
||||
*/
|
||||
module.exports.multiLineString = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
|
||||
return feature({
|
||||
type: 'MultiLineString',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a {@link Feature<MultiPoint>} based on a
|
||||
* coordinate array. Properties can be added optionally.
|
||||
*
|
||||
* @name multiPoint
|
||||
* @param {Array<Array<number>>} coordinates an array of Positions
|
||||
* @param {Object=} properties an Object of key-value pairs to add as properties
|
||||
* @returns {Feature<MultiPoint>} a MultiPoint feature
|
||||
* @throws {Error} if no coordinates are passed
|
||||
* @example
|
||||
* var multiPt = turf.multiPoint([[0,0],[10,10]]);
|
||||
*
|
||||
* //=multiPt
|
||||
*
|
||||
*/
|
||||
module.exports.multiPoint = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
|
||||
return feature({
|
||||
type: 'MultiPoint',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Creates a {@link Feature<MultiPolygon>} based on a
|
||||
* coordinate array. Properties can be added optionally.
|
||||
*
|
||||
* @name multiPolygon
|
||||
* @param {Array<Array<Array<Array<number>>>>} coordinates an array of Polygons
|
||||
* @param {Object=} properties an Object of key-value pairs to add as properties
|
||||
* @returns {Feature<MultiPolygon>} a multipolygon feature
|
||||
* @throws {Error} if no coordinates are passed
|
||||
* @example
|
||||
* var multiPoly = turf.multiPolygon([[[[0,0],[0,10],[10,10],[10,0],[0,0]]]]);
|
||||
*
|
||||
* //=multiPoly
|
||||
*
|
||||
*/
|
||||
module.exports.multiPolygon = function (coordinates, properties) {
|
||||
if (!coordinates) throw new Error('No coordinates passed');
|
||||
|
||||
return feature({
|
||||
type: 'MultiPolygon',
|
||||
coordinates: coordinates
|
||||
}, properties);
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a {@link Feature<GeometryCollection>} based on a
|
||||
* coordinate array. Properties can be added optionally.
|
||||
*
|
||||
* @name geometryCollection
|
||||
* @param {Array<{Geometry}>} geometries an array of GeoJSON Geometries
|
||||
* @param {Object=} properties an Object of key-value pairs to add as properties
|
||||
* @returns {Feature<GeometryCollection>} a GeoJSON GeometryCollection Feature
|
||||
* @example
|
||||
* var pt = {
|
||||
* "type": "Point",
|
||||
* "coordinates": [100, 0]
|
||||
* };
|
||||
* var line = {
|
||||
* "type": "LineString",
|
||||
* "coordinates": [ [101, 0], [102, 1] ]
|
||||
* };
|
||||
* var collection = turf.geometryCollection([pt, line]);
|
||||
*
|
||||
* //=collection
|
||||
*/
|
||||
module.exports.geometryCollection = function (geometries, properties) {
|
||||
if (!geometries) throw new Error('No geometries passed');
|
||||
|
||||
return feature({
|
||||
type: 'GeometryCollection',
|
||||
geometries: geometries
|
||||
}, properties);
|
||||
};
|
||||
|
||||
var factors = {
|
||||
miles: 3960,
|
||||
nauticalmiles: 3441.145,
|
||||
degrees: 57.2957795,
|
||||
radians: 1,
|
||||
inches: 250905600,
|
||||
yards: 6969600,
|
||||
meters: 6373000,
|
||||
metres: 6373000,
|
||||
kilometers: 6373,
|
||||
kilometres: 6373,
|
||||
feet: 20908792.65
|
||||
};
|
||||
|
||||
/*
|
||||
* Convert a distance measurement from radians to a more friendly unit.
|
||||
*
|
||||
* @name radiansToDistance
|
||||
* @param {number} distance in radians across the sphere
|
||||
* @param {string} [units=kilometers] can be degrees, radians, miles, or kilometers
|
||||
* inches, yards, metres, meters, kilometres, kilometers.
|
||||
* @returns {number} distance
|
||||
*/
|
||||
module.exports.radiansToDistance = function (radians, units) {
|
||||
var factor = factors[units || 'kilometers'];
|
||||
if (factor === undefined) throw new Error('Invalid unit');
|
||||
|
||||
return radians * factor;
|
||||
};
|
||||
|
||||
/*
|
||||
* Convert a distance measurement from a real-world unit into radians
|
||||
*
|
||||
* @name distanceToRadians
|
||||
* @param {number} distance in real units
|
||||
* @param {string} [units=kilometers] can be degrees, radians, miles, or kilometers
|
||||
* inches, yards, metres, meters, kilometres, kilometers.
|
||||
* @returns {number} radians
|
||||
*/
|
||||
module.exports.distanceToRadians = function (distance, units) {
|
||||
var factor = factors[units || 'kilometers'];
|
||||
if (factor === undefined) throw new Error('Invalid unit');
|
||||
|
||||
return distance / factor;
|
||||
};
|
||||
|
||||
/*
|
||||
* Convert a distance measurement from a real-world unit into degrees
|
||||
*
|
||||
* @name distanceToRadians
|
||||
* @param {number} distance in real units
|
||||
* @param {string} [units=kilometers] can be degrees, radians, miles, or kilometers
|
||||
* inches, yards, metres, meters, kilometres, kilometers.
|
||||
* @returns {number} degrees
|
||||
*/
|
||||
module.exports.distanceToDegrees = function (distance, units) {
|
||||
var factor = factors[units || 'kilometers'];
|
||||
if (factor === undefined) throw new Error('Invalid unit');
|
||||
|
||||
return (distance / factor) * 57.2958;
|
||||
};
|
||||
67
immoweb/node_modules/@turf/helpers/package.json
generated
vendored
Normal file
67
immoweb/node_modules/@turf/helpers/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
{
|
||||
"_from": "@turf/helpers@^3.13.0",
|
||||
"_id": "@turf/helpers@3.13.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-0GB4oUZM9WzbfqYk6h4TpxuIuAY=",
|
||||
"_location": "/@turf/helpers",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/helpers@^3.13.0",
|
||||
"name": "@turf/helpers",
|
||||
"escapedName": "@turf%2fhelpers",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.13.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.13.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@turf/center",
|
||||
"/@turf/destination",
|
||||
"/@turf/distance",
|
||||
"/@turf/hex-grid"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/helpers/-/helpers-3.13.0.tgz",
|
||||
"_shasum": "d06078a1464cf56cdb7ea624ea1e13a71b88b806",
|
||||
"_spec": "@turf/helpers@^3.13.0",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/@turf/center",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {},
|
||||
"deprecated": false,
|
||||
"description": "turf helpers module",
|
||||
"devDependencies": {
|
||||
"benchmark": "^2.1.3",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"geo",
|
||||
"point",
|
||||
"turf",
|
||||
"geojson"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/helpers",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.13.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/hex-grid/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/hex-grid/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
53
immoweb/node_modules/@turf/hex-grid/README.md
generated
vendored
Normal file
53
immoweb/node_modules/@turf/hex-grid/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
# @turf/hex-grid
|
||||
|
||||
# hexGrid
|
||||
|
||||
Takes a bounding box and a cell size in degrees and returns a [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects) of flat-topped
|
||||
hexagons ([Polygon](http://geojson.org/geojson-spec.html#polygon) features) aligned in an "odd-q" vertical grid as
|
||||
described in [Hexagonal Grids](http://www.redblobgames.com/grids/hexagons/).
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `bbox` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>** extent in [minX, minY, maxX, maxY] order
|
||||
- `cellSize` **[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** dimension of cell in specified units
|
||||
- `units` **\[[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)]** used in calculating cellSize, can be degrees, radians, miles, or kilometers (optional, default `kilometers`)
|
||||
- `triangles` **\[[boolean](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)]** whether to return as triangles instead of hexagons (optional, default `false`)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var bbox = [-96,31,-84,40];
|
||||
var cellSize = 50;
|
||||
var units = 'miles';
|
||||
|
||||
var hexgrid = turf.hexGrid(bbox, cellSize, units);
|
||||
|
||||
//=hexgrid
|
||||
```
|
||||
|
||||
Returns **[FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects)<[Polygon](http://geojson.org/geojson-spec.html#polygon)>** a hexagonal grid
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/hex-grid
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
8
immoweb/node_modules/@turf/hex-grid/index.d.ts
generated
vendored
Normal file
8
immoweb/node_modules/@turf/hex-grid/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
import {Units, BBox, Polygons} from '@turf/helpers'
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#hexgrid
|
||||
*/
|
||||
declare function hexGrid(bbox: BBox, cellSize: number, units?: Units, triangles?: boolean): Polygons;
|
||||
declare namespace hexGrid { }
|
||||
export = hexGrid;
|
||||
130
immoweb/node_modules/@turf/hex-grid/index.js
generated
vendored
Normal file
130
immoweb/node_modules/@turf/hex-grid/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,130 @@
|
|||
var point = require('@turf/helpers').point;
|
||||
var polygon = require('@turf/helpers').polygon;
|
||||
var distance = require('@turf/distance');
|
||||
var featurecollection = require('@turf/helpers').featureCollection;
|
||||
|
||||
//Precompute cosines and sines of angles used in hexagon creation
|
||||
// for performance gain
|
||||
var cosines = [];
|
||||
var sines = [];
|
||||
for (var i = 0; i < 6; i++) {
|
||||
var angle = 2 * Math.PI / 6 * i;
|
||||
cosines.push(Math.cos(angle));
|
||||
sines.push(Math.sin(angle));
|
||||
}
|
||||
|
||||
/**
|
||||
* Takes a bounding box and a cell size in degrees and returns a {@link FeatureCollection} of flat-topped
|
||||
* hexagons ({@link Polygon} features) aligned in an "odd-q" vertical grid as
|
||||
* described in [Hexagonal Grids](http://www.redblobgames.com/grids/hexagons/).
|
||||
*
|
||||
* @name hexGrid
|
||||
* @param {Array<number>} bbox extent in [minX, minY, maxX, maxY] order
|
||||
* @param {number} cellSize dimension of cell in specified units
|
||||
* @param {string} [units=kilometers] used in calculating cellSize, can be degrees, radians, miles, or kilometers
|
||||
* @param {boolean} [triangles=false] whether to return as triangles instead of hexagons
|
||||
* @returns {FeatureCollection<Polygon>} a hexagonal grid
|
||||
* @example
|
||||
* var bbox = [-96,31,-84,40];
|
||||
* var cellSize = 50;
|
||||
* var units = 'miles';
|
||||
*
|
||||
* var hexgrid = turf.hexGrid(bbox, cellSize, units);
|
||||
*
|
||||
* //=hexgrid
|
||||
*/
|
||||
module.exports = function hexGrid(bbox, cellSize, units, triangles) {
|
||||
var xFraction = cellSize / (distance(point([bbox[0], bbox[1]]), point([bbox[2], bbox[1]]), units));
|
||||
var cellWidth = xFraction * (bbox[2] - bbox[0]);
|
||||
var yFraction = cellSize / (distance(point([bbox[0], bbox[1]]), point([bbox[0], bbox[3]]), units));
|
||||
var cellHeight = yFraction * (bbox[3] - bbox[1]);
|
||||
var radius = cellWidth / 2;
|
||||
|
||||
var hex_width = radius * 2;
|
||||
var hex_height = Math.sqrt(3) / 2 * cellHeight;
|
||||
|
||||
var box_width = bbox[2] - bbox[0];
|
||||
var box_height = bbox[3] - bbox[1];
|
||||
|
||||
var x_interval = 3 / 4 * hex_width;
|
||||
var y_interval = hex_height;
|
||||
|
||||
var x_span = box_width / (hex_width - radius / 2);
|
||||
var x_count = Math.ceil(x_span);
|
||||
if (Math.round(x_span) === x_count) {
|
||||
x_count++;
|
||||
}
|
||||
|
||||
var x_adjust = ((x_count * x_interval - radius / 2) - box_width) / 2 - radius / 2;
|
||||
|
||||
var y_count = Math.ceil(box_height / hex_height);
|
||||
|
||||
var y_adjust = (box_height - y_count * hex_height) / 2;
|
||||
|
||||
var hasOffsetY = y_count * hex_height - box_height > hex_height / 2;
|
||||
if (hasOffsetY) {
|
||||
y_adjust -= hex_height / 4;
|
||||
}
|
||||
|
||||
var fc = featurecollection([]);
|
||||
for (var x = 0; x < x_count; x++) {
|
||||
for (var y = 0; y <= y_count; y++) {
|
||||
|
||||
var isOdd = x % 2 === 1;
|
||||
if (y === 0 && isOdd) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (y === 0 && hasOffsetY) {
|
||||
continue;
|
||||
}
|
||||
|
||||
var center_x = x * x_interval + bbox[0] - x_adjust;
|
||||
var center_y = y * y_interval + bbox[1] + y_adjust;
|
||||
|
||||
if (isOdd) {
|
||||
center_y -= hex_height / 2;
|
||||
}
|
||||
if (triangles) {
|
||||
fc.features.push.apply(fc.features, hexTriangles([center_x, center_y], cellWidth / 2, cellHeight / 2));
|
||||
} else {
|
||||
fc.features.push(hexagon([center_x, center_y], cellWidth / 2, cellHeight / 2));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return fc;
|
||||
};
|
||||
|
||||
//Center should be [x, y]
|
||||
function hexagon(center, rx, ry) {
|
||||
var vertices = [];
|
||||
for (var i = 0; i < 6; i++) {
|
||||
var x = center[0] + rx * cosines[i];
|
||||
var y = center[1] + ry * sines[i];
|
||||
vertices.push([x, y]);
|
||||
}
|
||||
//first and last vertex must be the same
|
||||
vertices.push(vertices[0]);
|
||||
return polygon([vertices]);
|
||||
}
|
||||
|
||||
//Center should be [x, y]
|
||||
function hexTriangles(center, rx, ry) {
|
||||
var triangles = [];
|
||||
for (var i = 0; i < 6; i++) {
|
||||
var vertices = [];
|
||||
vertices.push(center);
|
||||
vertices.push([
|
||||
center[0] + rx * cosines[i],
|
||||
center[1] + ry * sines[i]
|
||||
]);
|
||||
vertices.push([
|
||||
center[0] + rx * cosines[(i + 1) % 6],
|
||||
center[1] + ry * sines[(i + 1) % 6]
|
||||
]);
|
||||
vertices.push(center);
|
||||
triangles.push(polygon([vertices]));
|
||||
}
|
||||
return triangles;
|
||||
}
|
||||
91
immoweb/node_modules/@turf/hex-grid/package.json
generated
vendored
Normal file
91
immoweb/node_modules/@turf/hex-grid/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,91 @@
|
|||
{
|
||||
"_from": "@turf/hex-grid@^3.10.3",
|
||||
"_id": "@turf/hex-grid@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-noA28SceUWS/ao8BfenA9JAtmp8=",
|
||||
"_location": "/@turf/hex-grid",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/hex-grid@^3.10.3",
|
||||
"name": "@turf/hex-grid",
|
||||
"escapedName": "@turf%2fhex-grid",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.10.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.10.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/hexgrid-heatmap"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/hex-grid/-/hex-grid-3.14.0.tgz",
|
||||
"_shasum": "9e8036f1271e5164bf6a8f017de9c0f4902d9a9f",
|
||||
"_spec": "@turf/hex-grid@^3.10.3",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/hexgrid-heatmap",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"contributors": [
|
||||
{
|
||||
"name": "jseppi"
|
||||
},
|
||||
{
|
||||
"name": "jvail"
|
||||
},
|
||||
{
|
||||
"name": "lyzidiamond"
|
||||
},
|
||||
{
|
||||
"name": "tmcw"
|
||||
}
|
||||
],
|
||||
"dependencies": {
|
||||
"@turf/distance": "^3.14.0",
|
||||
"@turf/helpers": "^3.13.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "turf hex-grid module",
|
||||
"devDependencies": {
|
||||
"@turf/bbox-polygon": "^3.14.0",
|
||||
"@turf/explode": "^3.14.0",
|
||||
"@turf/inside": "^3.14.0",
|
||||
"@turf/truncate": "^3.13.0",
|
||||
"benchmark": "^1.0.0",
|
||||
"eslint": "^3.15.0",
|
||||
"eslint-config-mourner": "^2.0.1",
|
||||
"load-json-file": "^2.0.0",
|
||||
"tape": "^3.5.0",
|
||||
"write-json-file": "^2.0.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"turf",
|
||||
"grid",
|
||||
"hexgrid",
|
||||
"hexbin",
|
||||
"points",
|
||||
"geojson"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/hex-grid",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/invariant/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/invariant/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
87
immoweb/node_modules/@turf/invariant/README.md
generated
vendored
Normal file
87
immoweb/node_modules/@turf/invariant/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,87 @@
|
|||
# @turf/invariant
|
||||
|
||||
# getCoord
|
||||
|
||||
Unwrap a coordinate from a Point Feature, Geometry or a single coordinate.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `obj` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<any> | [Geometry](http://geojson.org/geojson-spec.html#geometry) \| [Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Point](http://geojson.org/geojson-spec.html#point)>)** any value
|
||||
|
||||
Returns **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>** coordinates
|
||||
|
||||
# getCoords
|
||||
|
||||
Unwrap coordinates from a Feature, Geometry Object or an Array of numbers
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `obj` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<any> | [Geometry](http://geojson.org/geojson-spec.html#geometry) \| [Feature](http://geojson.org/geojson-spec.html#feature-objects)<any>)** any value
|
||||
|
||||
Returns **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<any>** coordinates
|
||||
|
||||
# geojsonType
|
||||
|
||||
Enforce expectations about types of GeoJSON objects for Turf.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `value` **GeoJSON** any GeoJSON object
|
||||
- `type` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** expected GeoJSON type
|
||||
- `name` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** name of calling function
|
||||
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if value is not the expected type.
|
||||
|
||||
# featureOf
|
||||
|
||||
Enforce expectations about types of [Feature](http://geojson.org/geojson-spec.html#feature-objects) inputs for Turf.
|
||||
Internally this uses [geojsonType](#geojsontype) to judge geometry types.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `feature` **[Feature](http://geojson.org/geojson-spec.html#feature-objects)** a feature with an expected geometry type
|
||||
- `type` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** expected GeoJSON type
|
||||
- `name` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** name of calling function
|
||||
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** error if value is not the expected type.
|
||||
|
||||
# collectionOf
|
||||
|
||||
Enforce expectations about types of [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects) inputs for Turf.
|
||||
Internally this uses [geojsonType](#geojsontype) to judge geometry types.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `featureCollection` **[FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects)** a FeatureCollection for which features will be judged
|
||||
- `type` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** expected GeoJSON type
|
||||
- `name` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** name of calling function
|
||||
|
||||
|
||||
- Throws **[Error](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error)** if value is not the expected type.
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/invariant
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
30
immoweb/node_modules/@turf/invariant/index.d.ts
generated
vendored
Normal file
30
immoweb/node_modules/@turf/invariant/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Feature = GeoJSON.Feature<any>
|
||||
type Features = GeoJSON.FeatureCollection<any>
|
||||
type GetCoord = Feature | any[] | GeoJSON.GeometryObject
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function getCoord(obj: GetCoord): Array<any>;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function getCoords(obj: GetCoord): Array<any>;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function geojsonType(value: Features, type: string, name: string): void;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function featureOf(feature: Feature, type: string, name: string): void
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/
|
||||
*/
|
||||
export function collectionOf(featurecollection: Features, type: string, name: string): void
|
||||
140
immoweb/node_modules/@turf/invariant/index.js
generated
vendored
Normal file
140
immoweb/node_modules/@turf/invariant/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,140 @@
|
|||
/**
|
||||
* Unwrap a coordinate from a Point Feature, Geometry or a single coordinate.
|
||||
*
|
||||
* @param {Array<any>|Geometry|Feature<Point>} obj any value
|
||||
* @returns {Array<number>} coordinates
|
||||
*/
|
||||
function getCoord(obj) {
|
||||
if (!obj) throw new Error('No obj passed');
|
||||
|
||||
var coordinates = getCoords(obj);
|
||||
|
||||
// getCoord() must contain at least two numbers (Point)
|
||||
if (coordinates.length > 1 &&
|
||||
typeof coordinates[0] === 'number' &&
|
||||
typeof coordinates[1] === 'number') {
|
||||
return coordinates;
|
||||
} else {
|
||||
throw new Error('Coordinate is not a valid Point');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Unwrap coordinates from a Feature, Geometry Object or an Array of numbers
|
||||
*
|
||||
* @param {Array<any>|Geometry|Feature<any>} obj any value
|
||||
* @returns {Array<any>} coordinates
|
||||
*/
|
||||
function getCoords(obj) {
|
||||
if (!obj) throw new Error('No obj passed');
|
||||
var coordinates;
|
||||
|
||||
// Array of numbers
|
||||
if (obj.length) {
|
||||
coordinates = obj;
|
||||
|
||||
// Geometry Object
|
||||
} else if (obj.coordinates) {
|
||||
coordinates = obj.coordinates;
|
||||
|
||||
// Feature
|
||||
} else if (obj.geometry && obj.geometry.coordinates) {
|
||||
coordinates = obj.geometry.coordinates;
|
||||
}
|
||||
// Checks if coordinates contains a number
|
||||
if (coordinates) {
|
||||
containsNumber(coordinates);
|
||||
return coordinates;
|
||||
}
|
||||
throw new Error('No valid coordinates');
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if coordinates contains a number
|
||||
*
|
||||
* @private
|
||||
* @param {Array<any>} coordinates GeoJSON Coordinates
|
||||
* @returns {boolean} true if Array contains a number
|
||||
*/
|
||||
function containsNumber(coordinates) {
|
||||
if (coordinates.length > 1 &&
|
||||
typeof coordinates[0] === 'number' &&
|
||||
typeof coordinates[1] === 'number') {
|
||||
return true;
|
||||
}
|
||||
if (coordinates[0].length) {
|
||||
return containsNumber(coordinates[0]);
|
||||
}
|
||||
throw new Error('coordinates must only contain numbers');
|
||||
}
|
||||
|
||||
/**
|
||||
* Enforce expectations about types of GeoJSON objects for Turf.
|
||||
*
|
||||
* @alias geojsonType
|
||||
* @param {GeoJSON} value any GeoJSON object
|
||||
* @param {string} type expected GeoJSON type
|
||||
* @param {string} name name of calling function
|
||||
* @throws {Error} if value is not the expected type.
|
||||
*/
|
||||
function geojsonType(value, type, name) {
|
||||
if (!type || !name) throw new Error('type and name required');
|
||||
|
||||
if (!value || value.type !== type) {
|
||||
throw new Error('Invalid input to ' + name + ': must be a ' + type + ', given ' + value.type);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Enforce expectations about types of {@link Feature} inputs for Turf.
|
||||
* Internally this uses {@link geojsonType} to judge geometry types.
|
||||
*
|
||||
* @alias featureOf
|
||||
* @param {Feature} feature a feature with an expected geometry type
|
||||
* @param {string} type expected GeoJSON type
|
||||
* @param {string} name name of calling function
|
||||
* @throws {Error} error if value is not the expected type.
|
||||
*/
|
||||
function featureOf(feature, type, name) {
|
||||
if (!feature) throw new Error('No feature passed');
|
||||
if (!name) throw new Error('.featureOf() requires a name');
|
||||
if (!feature || feature.type !== 'Feature' || !feature.geometry) {
|
||||
throw new Error('Invalid input to ' + name + ', Feature with geometry required');
|
||||
}
|
||||
if (!feature.geometry || feature.geometry.type !== type) {
|
||||
throw new Error('Invalid input to ' + name + ': must be a ' + type + ', given ' + feature.geometry.type);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Enforce expectations about types of {@link FeatureCollection} inputs for Turf.
|
||||
* Internally this uses {@link geojsonType} to judge geometry types.
|
||||
*
|
||||
* @alias collectionOf
|
||||
* @param {FeatureCollection} featureCollection a FeatureCollection for which features will be judged
|
||||
* @param {string} type expected GeoJSON type
|
||||
* @param {string} name name of calling function
|
||||
* @throws {Error} if value is not the expected type.
|
||||
*/
|
||||
function collectionOf(featureCollection, type, name) {
|
||||
if (!featureCollection) throw new Error('No featureCollection passed');
|
||||
if (!name) throw new Error('.collectionOf() requires a name');
|
||||
if (!featureCollection || featureCollection.type !== 'FeatureCollection') {
|
||||
throw new Error('Invalid input to ' + name + ', FeatureCollection required');
|
||||
}
|
||||
for (var i = 0; i < featureCollection.features.length; i++) {
|
||||
var feature = featureCollection.features[i];
|
||||
if (!feature || feature.type !== 'Feature' || !feature.geometry) {
|
||||
throw new Error('Invalid input to ' + name + ', Feature with geometry required');
|
||||
}
|
||||
if (!feature.geometry || feature.geometry.type !== type) {
|
||||
throw new Error('Invalid input to ' + name + ': must be a ' + type + ', given ' + feature.geometry.type);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module.exports.geojsonType = geojsonType;
|
||||
module.exports.collectionOf = collectionOf;
|
||||
module.exports.featureOf = featureOf;
|
||||
module.exports.getCoord = getCoord;
|
||||
module.exports.getCoords = getCoords;
|
||||
65
immoweb/node_modules/@turf/invariant/package.json
generated
vendored
Normal file
65
immoweb/node_modules/@turf/invariant/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,65 @@
|
|||
{
|
||||
"_from": "@turf/invariant@^3.13.0",
|
||||
"_id": "@turf/invariant@3.13.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-iSQzCM1WMgboHlxhYuDSL2GCL5A=",
|
||||
"_location": "/@turf/invariant",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/invariant@^3.13.0",
|
||||
"name": "@turf/invariant",
|
||||
"escapedName": "@turf%2finvariant",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.13.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.13.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@turf/destination",
|
||||
"/@turf/distance"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/invariant/-/invariant-3.13.0.tgz",
|
||||
"_shasum": "89243308cd563206e81e5c6162e0d22f61822f90",
|
||||
"_spec": "@turf/invariant@^3.13.0",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/@turf/destination",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {},
|
||||
"deprecated": false,
|
||||
"description": "turf invariant module",
|
||||
"devDependencies": {
|
||||
"@turf/helpers": "^3.13.0",
|
||||
"benchmark": "^2.1.3",
|
||||
"tape": "^3.5.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"turf",
|
||||
"invariant",
|
||||
"expectations"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/invariant",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.13.0"
|
||||
}
|
||||
20
immoweb/node_modules/@turf/meta/LICENSE
generated
vendored
Normal file
20
immoweb/node_modules/@turf/meta/LICENSE
generated
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 TurfJS
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
403
immoweb/node_modules/@turf/meta/README.md
generated
vendored
Normal file
403
immoweb/node_modules/@turf/meta/README.md
generated
vendored
Normal file
|
|
@ -0,0 +1,403 @@
|
|||
# @turf/meta
|
||||
|
||||
# coordEach
|
||||
|
||||
Iterate over coordinates in any GeoJSON object, similar to Array.forEach()
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (currentCoords, currentIndex)
|
||||
- `excludeWrapCoord` **\[[boolean](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)]** whether or not to include
|
||||
the final coordinate of LinearRings that wraps the ring in its iteration. (optional, default `false`)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.coordEach(features, function (currentCoords, currentIndex) {
|
||||
//=currentCoords
|
||||
//=currentIndex
|
||||
});
|
||||
```
|
||||
|
||||
# coordReduce
|
||||
|
||||
Reduce coordinates in any GeoJSON object, similar to Array.reduce()
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (previousValue, currentCoords, currentIndex)
|
||||
- `initialValue` **\[Any]** Value to use as the first argument to the first call of the callback.
|
||||
- `excludeWrapCoord` **\[[boolean](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)]** whether or not to include
|
||||
the final coordinate of LinearRings that wraps the ring in its iteration. (optional, default `false`)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.coordReduce(features, function (previousValue, currentCoords, currentIndex) {
|
||||
//=previousValue
|
||||
//=currentCoords
|
||||
//=currentIndex
|
||||
return currentCoords;
|
||||
});
|
||||
```
|
||||
|
||||
Returns **Any** The value that results from the reduction.
|
||||
|
||||
# propEach
|
||||
|
||||
Iterate over properties in any GeoJSON object, similar to Array.forEach()
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (currentProperties, currentIndex)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"foo": "bar"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"hello": "world"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.propEach(features, function (currentProperties, currentIndex) {
|
||||
//=currentProperties
|
||||
//=currentIndex
|
||||
});
|
||||
```
|
||||
|
||||
# propReduce
|
||||
|
||||
Reduce properties in any GeoJSON object into a single value,
|
||||
similar to how Array.reduce works. However, in this case we lazily run
|
||||
the reduction, so an array of all properties is unnecessary.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (previousValue, currentProperties, currentIndex)
|
||||
- `initialValue` **\[Any]** Value to use as the first argument to the first call of the callback.
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"foo": "bar"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"hello": "world"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.propReduce(features, function (previousValue, currentProperties, currentIndex) {
|
||||
//=previousValue
|
||||
//=currentProperties
|
||||
//=currentIndex
|
||||
return currentProperties
|
||||
});
|
||||
```
|
||||
|
||||
Returns **Any** The value that results from the reduction.
|
||||
|
||||
# featureEach
|
||||
|
||||
Iterate over features in any GeoJSON object, similar to
|
||||
Array.forEach.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (currentFeature, currentIndex)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.featureEach(features, function (currentFeature, currentIndex) {
|
||||
//=currentFeature
|
||||
//=currentIndex
|
||||
});
|
||||
```
|
||||
|
||||
# featureReduce
|
||||
|
||||
Reduce features in any GeoJSON object, similar to Array.reduce().
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (previousValue, currentFeature, currentIndex)
|
||||
- `initialValue` **\[Any]** Value to use as the first argument to the first call of the callback.
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"foo": "bar"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"hello": "world"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.featureReduce(features, function (previousValue, currentFeature, currentIndex) {
|
||||
//=previousValue
|
||||
//=currentFeature
|
||||
//=currentIndex
|
||||
return currentFeature
|
||||
});
|
||||
```
|
||||
|
||||
Returns **Any** The value that results from the reduction.
|
||||
|
||||
# coordAll
|
||||
|
||||
Get all coordinates from any GeoJSON object.
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
var coords = turf.coordAll(features);
|
||||
//=coords
|
||||
```
|
||||
|
||||
Returns **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>** coordinate position array
|
||||
|
||||
# geomEach
|
||||
|
||||
Iterate over each geometry in any GeoJSON object, similar to Array.forEach()
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (currentGeometry, currentIndex)
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.geomEach(features, function (currentGeometry, currentIndex) {
|
||||
//=currentGeometry
|
||||
//=currentIndex
|
||||
});
|
||||
```
|
||||
|
||||
# geomReduce
|
||||
|
||||
Reduce geometry in any GeoJSON object, similar to Array.reduce().
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `layer` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** any GeoJSON object
|
||||
- `callback` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** a method that takes (previousValue, currentGeometry, currentIndex)
|
||||
- `initialValue` **\[Any]** Value to use as the first argument to the first call of the callback.
|
||||
|
||||
**Examples**
|
||||
|
||||
```javascript
|
||||
var features = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"foo": "bar"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [26, 37]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {"hello": "world"},
|
||||
"geometry": {
|
||||
"type": "Point",
|
||||
"coordinates": [36, 53]
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
turf.geomReduce(features, function (previousValue, currentGeometry, currentIndex) {
|
||||
//=previousValue
|
||||
//=currentGeometry
|
||||
//=currentIndex
|
||||
return currentGeometry
|
||||
});
|
||||
```
|
||||
|
||||
Returns **Any** The value that results from the reduction.
|
||||
|
||||
<!-- This file is automatically generated. Please don't edit it directly:
|
||||
if you find an error, edit the source file (likely index.js), and re-run
|
||||
./scripts/generate-readmes in the turf project. -->
|
||||
|
||||
---
|
||||
|
||||
This module is part of the [Turfjs project](http://turfjs.org/), an open source
|
||||
module collection dedicated to geographic algorithms. It is maintained in the
|
||||
[Turfjs/turf](https://github.com/Turfjs/turf) repository, where you can create
|
||||
PRs and issues.
|
||||
|
||||
### Installation
|
||||
|
||||
Install this module individually:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/meta
|
||||
```
|
||||
|
||||
Or install the Turf module that includes it as a function:
|
||||
|
||||
```sh
|
||||
$ npm install @turf/turf
|
||||
```
|
||||
101
immoweb/node_modules/@turf/meta/index.d.ts
generated
vendored
Normal file
101
immoweb/node_modules/@turf/meta/index.d.ts
generated
vendored
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
/// <reference types="geojson" />
|
||||
|
||||
type Points = GeoJSON.FeatureCollection<GeoJSON.Point>
|
||||
type Point = GeoJSON.Feature<GeoJSON.Point> | GeoJSON.Point
|
||||
type MultiPoints = GeoJSON.FeatureCollection<GeoJSON.MultiPoint>
|
||||
type MultiPoint = GeoJSON.Feature<GeoJSON.MultiPoint> | GeoJSON.MultiPoint
|
||||
type LineStrings = GeoJSON.FeatureCollection<GeoJSON.LineString>
|
||||
type LineString = GeoJSON.Feature<GeoJSON.LineString> | GeoJSON.LineString
|
||||
type MultiLineStrings = GeoJSON.FeatureCollection<GeoJSON.MultiLineString>
|
||||
type MultiLineString = GeoJSON.Feature<GeoJSON.MultiLineString> | GeoJSON.MultiLineString
|
||||
type Polygons = GeoJSON.FeatureCollection<GeoJSON.Polygon>
|
||||
type Polygon = GeoJSON.Feature<GeoJSON.Polygon> | GeoJSON.Polygon
|
||||
type MultiPolygons = GeoJSON.FeatureCollection<GeoJSON.MultiPolygon>
|
||||
type MultiPolygon = GeoJSON.Feature<GeoJSON.MultiPolygon> | GeoJSON.MultiPolygon
|
||||
type Feature = GeoJSON.Feature<any>
|
||||
type Features = GeoJSON.FeatureCollection<any>
|
||||
type GeometryCollection = GeoJSON.GeometryCollection
|
||||
type GeometryObject = GeoJSON.GeometryObject
|
||||
|
||||
interface MetaStatic {
|
||||
/**
|
||||
* http://turfjs.org/docs/#coordeach
|
||||
*/
|
||||
coordEach(layer: Points | Point | MultiPoint | MultiPoints, callback: (currentCoords: Array<number>, currentIndex: number) => void, excludeWrapCoord?: boolean): void;
|
||||
coordEach(layer: LineStrings | LineString | MultiLineString | MultiLineStrings, callback: (currentCoords: Array<Array<number>>, currentIndex: number) => void, excludeWrapCoord?: boolean): void;
|
||||
coordEach(layer: Polygons | Polygon | MultiPolygons | MultiPolygon, callback: (currentCoords: Array<Array<Array<number>>>, currentIndex: number) => void, excludeWrapCoord?: boolean): void;
|
||||
coordEach(layer: GeometryCollection | GeometryObject, callback: (currentCoords: Array<any>, currentIndex: number) => void, excludeWrapCoord?: boolean): void;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#coordreduce
|
||||
*/
|
||||
coordReduce(layer: Points | Point | MultiPoint | MultiPoints, callback: (previousValue: any, currentCoords: Array<number>, currentIndex: number) => void, initialValue: any, excludeWrapCoord?: boolean): any;
|
||||
coordReduce(layer: LineStrings | LineString | MultiLineString | MultiLineStrings, callback: (previousValue: any, currentCoords: Array<Array<number>>, currentIndex: number) => void, initialValue: any, excludeWrapCoord?: boolean): any;
|
||||
coordReduce(layer: Polygons | Polygon | MultiPolygons | MultiPolygon, callback: (previousValue: any, currentCoords: Array<Array<Array<number>>>, currentIndex: number) => void, initialValue: any, excludeWrapCoord?: boolean): any;
|
||||
coordReduce(layer: GeometryCollection | GeometryObject, callback: (previousValue: any, currentCoords: Array<any>, currentIndex: number) => void, initialValue: any, excludeWrapCoord?: boolean): any;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#propeach
|
||||
*/
|
||||
propEach(layer: Feature | Features, callback: (currentProperties: any, currentIndex: number) => void): void;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#propreduce
|
||||
*/
|
||||
propReduce(layer: Feature | Features, callback: (previousValue: any, currentProperties: any, currentIndex: number) => void, initialValue: any): any;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#featurereduce
|
||||
*/
|
||||
featureReduce(layer: Point | Points, callback: (previousValue: any, currentFeature: Point, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: LineString | LineStrings, callback: (previousValue: any, currentFeature: LineString, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: Polygon | Polygons, callback: (previousValue: any, currentFeature: Polygon, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: MultiPoint | MultiPoints, callback: (previousValue: any, currentFeature: MultiPoint, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: MultiLineString | MultiLineStrings, callback: (previousValue: any, currentFeature: MultiLineString, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: MultiPolygon | MultiPolygons, callback: (previousValue: any, currentFeature: MultiPolygon, currentIndex: number) => void, initialValue: any): any;
|
||||
featureReduce(layer: Feature | Features, callback: (previousValue: any, currentFeature: Feature, currentIndex: number) => void, initialValue: any): any;
|
||||
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#featureeach
|
||||
*/
|
||||
featureEach(layer: Point | Points, callback: (currentFeature: Point, currentIndex: number) => void): void;
|
||||
featureEach(layer: LineString | LineStrings, callback: (currentFeature: LineString, currentIndex: number) => void): void;
|
||||
featureEach(layer: Polygon | Polygons, callback: (currentFeature: Polygon, currentIndex: number) => void): void;
|
||||
featureEach(layer: MultiPoint | MultiPoints, callback: (currentFeature: MultiPoint, currentIndex: number) => void): void;
|
||||
featureEach(layer: MultiLineString | MultiLineStrings, callback: (currentFeature: MultiLineString, currentIndex: number) => void): void;
|
||||
featureEach(layer: MultiPolygon | MultiPolygons, callback: (currentFeature: MultiPolygon, currentIndex: number) => void): void;
|
||||
featureEach(layer: Feature | Features, callback: (currentFeature: Feature, currentIndex: number) => void): void;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#coordall
|
||||
*/
|
||||
coordAll(layer: Feature | Features | GeometryCollection | GeometryObject): Array<Array<number>>
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#geomreduce
|
||||
*/
|
||||
geomReduce(layer: Point | Points, callback: (previousValue: any, currentGeometry: GeoJSON.Point, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: LineString | LineStrings, callback: (previousValue: any, currentGeometry: GeoJSON.LineString, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: Polygon | Polygons, callback: (previousValue: any, currentGeometry: GeoJSON.Polygon, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: MultiPoint | MultiPoints, callback: (previousValue: any, currentGeometry: GeoJSON.MultiPoint, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: MultiLineString | MultiLineStrings, callback: (previousValue: any, currentGeometry: GeoJSON.MultiLineString, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: MultiPolygon | MultiPolygons, callback: (previousValue: any, currentGeometry: GeoJSON.MultiPolygon, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: Feature | Features, callback: (previousValue: any, currentGeometry: GeometryObject, currentIndex: number) => void, initialValue: any): any;
|
||||
geomReduce(layer: GeometryCollection | GeometryObject, callback: (previousValue: any, currentGeometry: GeometryObject, currentIndex: number) => void, initialValue: any): any;
|
||||
|
||||
/**
|
||||
* http://turfjs.org/docs/#geomeach
|
||||
*/
|
||||
geomEach(layer: Point | Points, callback: (currentGeometry: GeoJSON.Point, currentIndex: number) => void): void;
|
||||
geomEach(layer: LineString | LineStrings, callback: (currentGeometry: GeoJSON.LineString, currentIndex: number) => void): void;
|
||||
geomEach(layer: Polygon | Polygons, callback: (currentGeometry: GeoJSON.Polygon, currentIndex: number) => void): void;
|
||||
geomEach(layer: MultiPoint | MultiPoints, callback: (currentGeometry: GeoJSON.MultiPoint, currentIndex: number) => void): void;
|
||||
geomEach(layer: MultiLineString | MultiLineStrings, callback: (currentGeometry: GeoJSON.MultiLineString, currentIndex: number) => void): void;
|
||||
geomEach(layer: MultiPolygon | MultiPolygons, callback: (currentGeometry: GeoJSON.MultiPolygon, currentIndex: number) => void): void;
|
||||
geomEach(layer: Feature | Features, callback: (currentGeometry: GeometryObject, currentIndex: number) => void): void;
|
||||
geomEach(layer: GeometryCollection | GeometryObject, callback: (currentGeometry: GeometryObject, currentIndex: number) => void): void;
|
||||
}
|
||||
|
||||
declare const meta: MetaStatic
|
||||
export = meta
|
||||
650
immoweb/node_modules/@turf/meta/index.js
generated
vendored
Normal file
650
immoweb/node_modules/@turf/meta/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,650 @@
|
|||
/**
|
||||
* Callback for coordEach
|
||||
*
|
||||
* @private
|
||||
* @callback coordEachCallback
|
||||
* @param {[number, number]} currentCoords The current coordinates being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Iterate over coordinates in any GeoJSON object, similar to Array.forEach()
|
||||
*
|
||||
* @name coordEach
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (currentCoords, currentIndex)
|
||||
* @param {boolean} [excludeWrapCoord=false] whether or not to include
|
||||
* the final coordinate of LinearRings that wraps the ring in its iteration.
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.coordEach(features, function (currentCoords, currentIndex) {
|
||||
* //=currentCoords
|
||||
* //=currentIndex
|
||||
* });
|
||||
*/
|
||||
function coordEach(layer, callback, excludeWrapCoord) {
|
||||
var i, j, k, g, l, geometry, stopG, coords,
|
||||
geometryMaybeCollection,
|
||||
wrapShrink = 0,
|
||||
currentIndex = 0,
|
||||
isGeometryCollection,
|
||||
isFeatureCollection = layer.type === 'FeatureCollection',
|
||||
isFeature = layer.type === 'Feature',
|
||||
stop = isFeatureCollection ? layer.features.length : 1;
|
||||
|
||||
// This logic may look a little weird. The reason why it is that way
|
||||
// is because it's trying to be fast. GeoJSON supports multiple kinds
|
||||
// of objects at its root: FeatureCollection, Features, Geometries.
|
||||
// This function has the responsibility of handling all of them, and that
|
||||
// means that some of the `for` loops you see below actually just don't apply
|
||||
// to certain inputs. For instance, if you give this just a
|
||||
// Point geometry, then both loops are short-circuited and all we do
|
||||
// is gradually rename the input until it's called 'geometry'.
|
||||
//
|
||||
// This also aims to allocate as few resources as possible: just a
|
||||
// few numbers and booleans, rather than any temporary arrays as would
|
||||
// be required with the normalization approach.
|
||||
for (i = 0; i < stop; i++) {
|
||||
|
||||
geometryMaybeCollection = (isFeatureCollection ? layer.features[i].geometry :
|
||||
(isFeature ? layer.geometry : layer));
|
||||
isGeometryCollection = geometryMaybeCollection.type === 'GeometryCollection';
|
||||
stopG = isGeometryCollection ? geometryMaybeCollection.geometries.length : 1;
|
||||
|
||||
for (g = 0; g < stopG; g++) {
|
||||
geometry = isGeometryCollection ?
|
||||
geometryMaybeCollection.geometries[g] : geometryMaybeCollection;
|
||||
coords = geometry.coordinates;
|
||||
|
||||
wrapShrink = (excludeWrapCoord &&
|
||||
(geometry.type === 'Polygon' || geometry.type === 'MultiPolygon')) ?
|
||||
1 : 0;
|
||||
|
||||
if (geometry.type === 'Point') {
|
||||
callback(coords, currentIndex);
|
||||
currentIndex++;
|
||||
} else if (geometry.type === 'LineString' || geometry.type === 'MultiPoint') {
|
||||
for (j = 0; j < coords.length; j++) {
|
||||
callback(coords[j], currentIndex);
|
||||
currentIndex++;
|
||||
}
|
||||
} else if (geometry.type === 'Polygon' || geometry.type === 'MultiLineString') {
|
||||
for (j = 0; j < coords.length; j++)
|
||||
for (k = 0; k < coords[j].length - wrapShrink; k++) {
|
||||
callback(coords[j][k], currentIndex);
|
||||
currentIndex++;
|
||||
}
|
||||
} else if (geometry.type === 'MultiPolygon') {
|
||||
for (j = 0; j < coords.length; j++)
|
||||
for (k = 0; k < coords[j].length; k++)
|
||||
for (l = 0; l < coords[j][k].length - wrapShrink; l++) {
|
||||
callback(coords[j][k][l], currentIndex);
|
||||
currentIndex++;
|
||||
}
|
||||
} else if (geometry.type === 'GeometryCollection') {
|
||||
for (j = 0; j < geometry.geometries.length; j++)
|
||||
coordEach(geometry.geometries[j], callback, excludeWrapCoord);
|
||||
} else {
|
||||
throw new Error('Unknown Geometry Type');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
module.exports.coordEach = coordEach;
|
||||
|
||||
/**
|
||||
* Callback for coordReduce
|
||||
*
|
||||
* The first time the callback function is called, the values provided as arguments depend
|
||||
* on whether the reduce method has an initialValue argument.
|
||||
*
|
||||
* If an initialValue is provided to the reduce method:
|
||||
* - The previousValue argument is initialValue.
|
||||
* - The currentValue argument is the value of the first element present in the array.
|
||||
*
|
||||
* If an initialValue is not provided:
|
||||
* - The previousValue argument is the value of the first element present in the array.
|
||||
* - The currentValue argument is the value of the second element present in the array.
|
||||
*
|
||||
* @private
|
||||
* @callback coordReduceCallback
|
||||
* @param {*} previousValue The accumulated value previously returned in the last invocation
|
||||
* of the callback, or initialValue, if supplied.
|
||||
* @param {[number, number]} currentCoords The current coordinate being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Reduce coordinates in any GeoJSON object, similar to Array.reduce()
|
||||
*
|
||||
* @name coordReduce
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (previousValue, currentCoords, currentIndex)
|
||||
* @param {*} [initialValue] Value to use as the first argument to the first call of the callback.
|
||||
* @param {boolean} [excludeWrapCoord=false] whether or not to include
|
||||
* the final coordinate of LinearRings that wraps the ring in its iteration.
|
||||
* @returns {*} The value that results from the reduction.
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.coordReduce(features, function (previousValue, currentCoords, currentIndex) {
|
||||
* //=previousValue
|
||||
* //=currentCoords
|
||||
* //=currentIndex
|
||||
* return currentCoords;
|
||||
* });
|
||||
*/
|
||||
function coordReduce(layer, callback, initialValue, excludeWrapCoord) {
|
||||
var previousValue = initialValue;
|
||||
coordEach(layer, function (currentCoords, currentIndex) {
|
||||
if (currentIndex === 0 && initialValue === undefined) {
|
||||
previousValue = currentCoords;
|
||||
} else {
|
||||
previousValue = callback(previousValue, currentCoords, currentIndex);
|
||||
}
|
||||
}, excludeWrapCoord);
|
||||
return previousValue;
|
||||
}
|
||||
module.exports.coordReduce = coordReduce;
|
||||
|
||||
/**
|
||||
* Callback for propEach
|
||||
*
|
||||
* @private
|
||||
* @callback propEachCallback
|
||||
* @param {*} currentProperties The current properties being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Iterate over properties in any GeoJSON object, similar to Array.forEach()
|
||||
*
|
||||
* @name propEach
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (currentProperties, currentIndex)
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"foo": "bar"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"hello": "world"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.propEach(features, function (currentProperties, currentIndex) {
|
||||
* //=currentProperties
|
||||
* //=currentIndex
|
||||
* });
|
||||
*/
|
||||
function propEach(layer, callback) {
|
||||
var i;
|
||||
switch (layer.type) {
|
||||
case 'FeatureCollection':
|
||||
for (i = 0; i < layer.features.length; i++) {
|
||||
callback(layer.features[i].properties, i);
|
||||
}
|
||||
break;
|
||||
case 'Feature':
|
||||
callback(layer.properties, 0);
|
||||
break;
|
||||
}
|
||||
}
|
||||
module.exports.propEach = propEach;
|
||||
|
||||
|
||||
/**
|
||||
* Callback for propReduce
|
||||
*
|
||||
* The first time the callback function is called, the values provided as arguments depend
|
||||
* on whether the reduce method has an initialValue argument.
|
||||
*
|
||||
* If an initialValue is provided to the reduce method:
|
||||
* - The previousValue argument is initialValue.
|
||||
* - The currentValue argument is the value of the first element present in the array.
|
||||
*
|
||||
* If an initialValue is not provided:
|
||||
* - The previousValue argument is the value of the first element present in the array.
|
||||
* - The currentValue argument is the value of the second element present in the array.
|
||||
*
|
||||
* @private
|
||||
* @callback propReduceCallback
|
||||
* @param {*} previousValue The accumulated value previously returned in the last invocation
|
||||
* of the callback, or initialValue, if supplied.
|
||||
* @param {*} currentProperties The current properties being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Reduce properties in any GeoJSON object into a single value,
|
||||
* similar to how Array.reduce works. However, in this case we lazily run
|
||||
* the reduction, so an array of all properties is unnecessary.
|
||||
*
|
||||
* @name propReduce
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (previousValue, currentProperties, currentIndex)
|
||||
* @param {*} [initialValue] Value to use as the first argument to the first call of the callback.
|
||||
* @returns {*} The value that results from the reduction.
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"foo": "bar"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"hello": "world"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.propReduce(features, function (previousValue, currentProperties, currentIndex) {
|
||||
* //=previousValue
|
||||
* //=currentProperties
|
||||
* //=currentIndex
|
||||
* return currentProperties
|
||||
* });
|
||||
*/
|
||||
function propReduce(layer, callback, initialValue) {
|
||||
var previousValue = initialValue;
|
||||
propEach(layer, function (currentProperties, currentIndex) {
|
||||
if (currentIndex === 0 && initialValue === undefined) {
|
||||
previousValue = currentProperties;
|
||||
} else {
|
||||
previousValue = callback(previousValue, currentProperties, currentIndex);
|
||||
}
|
||||
});
|
||||
return previousValue;
|
||||
}
|
||||
module.exports.propReduce = propReduce;
|
||||
|
||||
/**
|
||||
* Callback for featureEach
|
||||
*
|
||||
* @private
|
||||
* @callback featureEachCallback
|
||||
* @param {Feature<any>} currentFeature The current feature being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Iterate over features in any GeoJSON object, similar to
|
||||
* Array.forEach.
|
||||
*
|
||||
* @name featureEach
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (currentFeature, currentIndex)
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.featureEach(features, function (currentFeature, currentIndex) {
|
||||
* //=currentFeature
|
||||
* //=currentIndex
|
||||
* });
|
||||
*/
|
||||
function featureEach(layer, callback) {
|
||||
if (layer.type === 'Feature') {
|
||||
callback(layer, 0);
|
||||
} else if (layer.type === 'FeatureCollection') {
|
||||
for (var i = 0; i < layer.features.length; i++) {
|
||||
callback(layer.features[i], i);
|
||||
}
|
||||
}
|
||||
}
|
||||
module.exports.featureEach = featureEach;
|
||||
|
||||
/**
|
||||
* Callback for featureReduce
|
||||
*
|
||||
* The first time the callback function is called, the values provided as arguments depend
|
||||
* on whether the reduce method has an initialValue argument.
|
||||
*
|
||||
* If an initialValue is provided to the reduce method:
|
||||
* - The previousValue argument is initialValue.
|
||||
* - The currentValue argument is the value of the first element present in the array.
|
||||
*
|
||||
* If an initialValue is not provided:
|
||||
* - The previousValue argument is the value of the first element present in the array.
|
||||
* - The currentValue argument is the value of the second element present in the array.
|
||||
*
|
||||
* @private
|
||||
* @callback featureReduceCallback
|
||||
* @param {*} previousValue The accumulated value previously returned in the last invocation
|
||||
* of the callback, or initialValue, if supplied.
|
||||
* @param {Feature<any>} currentFeature The current Feature being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Reduce features in any GeoJSON object, similar to Array.reduce().
|
||||
*
|
||||
* @name featureReduce
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (previousValue, currentFeature, currentIndex)
|
||||
* @param {*} [initialValue] Value to use as the first argument to the first call of the callback.
|
||||
* @returns {*} The value that results from the reduction.
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"foo": "bar"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"hello": "world"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.featureReduce(features, function (previousValue, currentFeature, currentIndex) {
|
||||
* //=previousValue
|
||||
* //=currentFeature
|
||||
* //=currentIndex
|
||||
* return currentFeature
|
||||
* });
|
||||
*/
|
||||
function featureReduce(layer, callback, initialValue) {
|
||||
var previousValue = initialValue;
|
||||
featureEach(layer, function (currentFeature, currentIndex) {
|
||||
if (currentIndex === 0 && initialValue === undefined) {
|
||||
previousValue = currentFeature;
|
||||
} else {
|
||||
previousValue = callback(previousValue, currentFeature, currentIndex);
|
||||
}
|
||||
});
|
||||
return previousValue;
|
||||
}
|
||||
module.exports.featureReduce = featureReduce;
|
||||
|
||||
/**
|
||||
* Get all coordinates from any GeoJSON object.
|
||||
*
|
||||
* @name coordAll
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @returns {Array<Array<number>>} coordinate position array
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* var coords = turf.coordAll(features);
|
||||
* //=coords
|
||||
*/
|
||||
function coordAll(layer) {
|
||||
var coords = [];
|
||||
coordEach(layer, function (coord) {
|
||||
coords.push(coord);
|
||||
});
|
||||
return coords;
|
||||
}
|
||||
module.exports.coordAll = coordAll;
|
||||
|
||||
/**
|
||||
* Iterate over each geometry in any GeoJSON object, similar to Array.forEach()
|
||||
*
|
||||
* @name geomEach
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (currentGeometry, currentIndex)
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.geomEach(features, function (currentGeometry, currentIndex) {
|
||||
* //=currentGeometry
|
||||
* //=currentIndex
|
||||
* });
|
||||
*/
|
||||
function geomEach(layer, callback) {
|
||||
var i, j, g, geometry, stopG,
|
||||
geometryMaybeCollection,
|
||||
isGeometryCollection,
|
||||
currentIndex = 0,
|
||||
isFeatureCollection = layer.type === 'FeatureCollection',
|
||||
isFeature = layer.type === 'Feature',
|
||||
stop = isFeatureCollection ? layer.features.length : 1;
|
||||
|
||||
// This logic may look a little weird. The reason why it is that way
|
||||
// is because it's trying to be fast. GeoJSON supports multiple kinds
|
||||
// of objects at its root: FeatureCollection, Features, Geometries.
|
||||
// This function has the responsibility of handling all of them, and that
|
||||
// means that some of the `for` loops you see below actually just don't apply
|
||||
// to certain inputs. For instance, if you give this just a
|
||||
// Point geometry, then both loops are short-circuited and all we do
|
||||
// is gradually rename the input until it's called 'geometry'.
|
||||
//
|
||||
// This also aims to allocate as few resources as possible: just a
|
||||
// few numbers and booleans, rather than any temporary arrays as would
|
||||
// be required with the normalization approach.
|
||||
for (i = 0; i < stop; i++) {
|
||||
|
||||
geometryMaybeCollection = (isFeatureCollection ? layer.features[i].geometry :
|
||||
(isFeature ? layer.geometry : layer));
|
||||
isGeometryCollection = geometryMaybeCollection.type === 'GeometryCollection';
|
||||
stopG = isGeometryCollection ? geometryMaybeCollection.geometries.length : 1;
|
||||
|
||||
for (g = 0; g < stopG; g++) {
|
||||
geometry = isGeometryCollection ?
|
||||
geometryMaybeCollection.geometries[g] : geometryMaybeCollection;
|
||||
|
||||
if (geometry.type === 'Point' ||
|
||||
geometry.type === 'LineString' ||
|
||||
geometry.type === 'MultiPoint' ||
|
||||
geometry.type === 'Polygon' ||
|
||||
geometry.type === 'MultiLineString' ||
|
||||
geometry.type === 'MultiPolygon') {
|
||||
callback(geometry, currentIndex);
|
||||
currentIndex++;
|
||||
} else if (geometry.type === 'GeometryCollection') {
|
||||
for (j = 0; j < geometry.geometries.length; j++) {
|
||||
callback(geometry.geometries[j], currentIndex);
|
||||
currentIndex++;
|
||||
}
|
||||
} else {
|
||||
throw new Error('Unknown Geometry Type');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
module.exports.geomEach = geomEach;
|
||||
|
||||
/**
|
||||
* Callback for geomReduce
|
||||
*
|
||||
* The first time the callback function is called, the values provided as arguments depend
|
||||
* on whether the reduce method has an initialValue argument.
|
||||
*
|
||||
* If an initialValue is provided to the reduce method:
|
||||
* - The previousValue argument is initialValue.
|
||||
* - The currentValue argument is the value of the first element present in the array.
|
||||
*
|
||||
* If an initialValue is not provided:
|
||||
* - The previousValue argument is the value of the first element present in the array.
|
||||
* - The currentValue argument is the value of the second element present in the array.
|
||||
*
|
||||
* @private
|
||||
* @callback geomReduceCallback
|
||||
* @param {*} previousValue The accumulated value previously returned in the last invocation
|
||||
* of the callback, or initialValue, if supplied.
|
||||
* @param {*} currentGeometry The current Feature being processed.
|
||||
* @param {number} currentIndex The index of the current element being processed in the
|
||||
* array.Starts at index 0, if an initialValue is provided, and at index 1 otherwise.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Reduce geometry in any GeoJSON object, similar to Array.reduce().
|
||||
*
|
||||
* @name geomReduce
|
||||
* @param {Object} layer any GeoJSON object
|
||||
* @param {Function} callback a method that takes (previousValue, currentGeometry, currentIndex)
|
||||
* @param {*} [initialValue] Value to use as the first argument to the first call of the callback.
|
||||
* @returns {*} The value that results from the reduction.
|
||||
* @example
|
||||
* var features = {
|
||||
* "type": "FeatureCollection",
|
||||
* "features": [
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"foo": "bar"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [26, 37]
|
||||
* }
|
||||
* },
|
||||
* {
|
||||
* "type": "Feature",
|
||||
* "properties": {"hello": "world"},
|
||||
* "geometry": {
|
||||
* "type": "Point",
|
||||
* "coordinates": [36, 53]
|
||||
* }
|
||||
* }
|
||||
* ]
|
||||
* };
|
||||
* turf.geomReduce(features, function (previousValue, currentGeometry, currentIndex) {
|
||||
* //=previousValue
|
||||
* //=currentGeometry
|
||||
* //=currentIndex
|
||||
* return currentGeometry
|
||||
* });
|
||||
*/
|
||||
function geomReduce(layer, callback, initialValue) {
|
||||
var previousValue = initialValue;
|
||||
geomEach(layer, function (currentGeometry, currentIndex) {
|
||||
if (currentIndex === 0 && initialValue === undefined) {
|
||||
previousValue = currentGeometry;
|
||||
} else {
|
||||
previousValue = callback(previousValue, currentGeometry, currentIndex);
|
||||
}
|
||||
});
|
||||
return previousValue;
|
||||
}
|
||||
module.exports.geomReduce = geomReduce;
|
||||
67
immoweb/node_modules/@turf/meta/package.json
generated
vendored
Normal file
67
immoweb/node_modules/@turf/meta/package.json
generated
vendored
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
{
|
||||
"_from": "@turf/meta@^3.14.0",
|
||||
"_id": "@turf/meta@3.14.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-jTBQwaD0S/QGpjO2vSjFEPe87ic=",
|
||||
"_location": "/@turf/meta",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "@turf/meta@^3.14.0",
|
||||
"name": "@turf/meta",
|
||||
"escapedName": "@turf%2fmeta",
|
||||
"scope": "@turf",
|
||||
"rawSpec": "^3.14.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^3.14.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@turf/bbox"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@turf/meta/-/meta-3.14.0.tgz",
|
||||
"_shasum": "8d3050c1a0f44bf406a633b6bd28c510f7bcee27",
|
||||
"_spec": "@turf/meta@^3.14.0",
|
||||
"_where": "/home/kadir/workspace/webimmo/node_modules/@turf/bbox",
|
||||
"author": {
|
||||
"name": "Turf Authors"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Turfjs/turf/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {},
|
||||
"deprecated": false,
|
||||
"description": "turf meta module",
|
||||
"devDependencies": {
|
||||
"@turf/helpers": "^3.13.0",
|
||||
"@turf/random": "^3.14.0",
|
||||
"benchmark": "^2.1.3",
|
||||
"eslint": "^3.14.1",
|
||||
"eslint-config-mourner": "^2.0.1",
|
||||
"tape": "^3.4.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js",
|
||||
"index.d.ts"
|
||||
],
|
||||
"homepage": "https://github.com/Turfjs/turf",
|
||||
"keywords": [
|
||||
"functional",
|
||||
"programming",
|
||||
"turfjs"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "index.js",
|
||||
"name": "@turf/meta",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/Turfjs/turf.git"
|
||||
},
|
||||
"scripts": {
|
||||
"bench": "node bench.js",
|
||||
"test": "node test.js"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue