{"name":"@turf/line-slice","version":"6.2.0-alpha.2","keywords":["turf","linestring","geojson","linear","reference","line","distance"],"author":{"name":"Turf Authors"},"license":"MIT","_id":"@turf/line-slice@6.2.0-alpha.2","homepage":"https://github.com/Turfjs/turf","bugs":{"url":"https://github.com/Turfjs/turf/issues"},"dist":{"shasum":"dbba3db2e892725a767f10c1af036efa26c75289","tarball":"http://registry-npm.ywwl.com/@turf/line-slice/download/@turf/line-slice-6.2.0-alpha.2.tgz","fileCount":7,"integrity":"sha512-NOzBGj6Jabfts/HLXejyNh8pOei95lrPN9bak6yMrvTiaziGjdcT3XF6mqwW6avOCEyeS/zsSPNksnh/87LWCg==","signatures":[{"sig":"MEUCIBAZcXNf3O+RbtORO3PlbtLNC+yrJAPXW08gIWuF/tv9AiEAtittyesNHGP2VDWoTqBcKVpp3tFcPGpZBybiDgeR2AQ=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":10753,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfDHRZCRA9TVsSAnZWagAAD6kP/3R5feCk8AiE3vE700+V\nus7eIwpzONOn8gV2l+0miAcXhhQSe+Nm9FhOvGQWsxPkwu8K4D244V78B8Er\ntVBIPQ4LKZFWwvN2eBgsSJwRsDBoC7AEYP1eNaIv4GqYrtO0gyRV2pWrgFxd\n1RrYT4Bptf13DoJF9YGrZxXKO7spAaEWOyHmpQZQ/QuWDvvK8J/SI+VjMsMI\nZngGFIYQmW9BNi7xRW5gfqachpza+SXfnLQmqskIQYDxoo83mWC6so02lRaB\nCBkNAjQYkAv/xNg/AQMDUPYBpVb+sYWr8QyrJULGNDvXhcyc5pNJ8bllEUP8\nFGtzRagaSwhjmnkWHt6yeZNNdIpyRHqYjW6oy0I0WLFKIjXQ3k6TPn5J1M70\nuPAQrNO7vA+UYqypXXbR5UZGPwRVo/N9oRhaW1qIWH1/Bh3Em9u4B6nvnrZW\nWR8CGDQfY3WzDrl9oSrP+0UvertLP9RbiqONxHLnjSNR+6FQO9e9nvLKjjFe\nQrC5Wa9MGU6c8TLtdwszC7TzmyUKCAPZzv+CpZIfY0x74Aw6nPfLlZasGawO\n9DfsSYkmZapncI2mgaAsW10Ht8ZNDUU1nsAk4gfTIO8Hq/jKLFk5MUyTz+FO\nXG7q+82Rb6yxAWFPaJWDSS9uj7/eQAJ+40ZqQmt0tYw575acEzw+3amO7zJs\nI4AB\r\n=Yj0v\r\n-----END PGP SIGNATURE-----\r\n","size":3111,"noattachment":false,"key":"/@turf/line-slice/-/@turf/line-slice-6.2.0-alpha.2.tgz"},"main":"dist/js/index.js","types":"index.d.ts","module":"dist/es/index.js","gitHead":"23d5cb91d77e0c1e2e903a2252f525797f1d0d09","scripts":{"docs":"node ../../scripts/generate-readmes","test":"npm-run-all prepare test:*","bench":"npm-run-all prepare bench:run","prepare":"rollup -c ../../rollup.config.js","posttest":"node -r esm ../../scripts/validate-es5-dependencies.js","bench:run":"node bench.js","test:tape":"node -r esm test.js"},"_npmUser":{"name":"mdfedderly","email":"mdfedderly@mdfedderly.com"},"repository":{"url":"git://github.com/Turfjs/turf.git","type":"git"},"_npmVersion":"lerna/3.20.2/node@v13.10.1+x64 (darwin)","description":"turf line-slice module","directories":{},"sideEffects":false,"_nodeVersion":"13.10.1","dependencies":{"@turf/helpers":"^6.2.0-alpha.2","@turf/invariant":"^6.2.0-alpha.2","@turf/nearest-point-on-line":"^6.2.0-alpha.2"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tape":"*","rollup":"*","benchmark":"*","npm-run-all":"*","@turf/truncate":"^6.2.0-alpha.2","load-json-file":"*","write-json-file":"*"},"_npmOperationalInternal":{"tmp":"tmp/line-slice_6.2.0-alpha.2_1594651737067_0.10419479126127329","host":"s3://npm-registry-packages"},"readme":"# @turf/line-slice\n\n<!-- Generated by documentation.js. Update this documentation by updating the source code. -->\n\n## lineSlice\n\nTakes a [line][1], a start [Point][2], and a stop point\nand returns a subsection of the line in-between those points.\nThe start & stop points don't need to fall exactly on the line.\n\nThis can be useful for extracting only the part of a route between waypoints.\n\n### Parameters\n\n*   `startPt` **[Coord][3]** starting point\n*   `stopPt` **[Coord][3]** stopping point\n*   `line` **([Feature][4]<[LineString][1]> | [LineString][1])** line to slice\n\n### Examples\n\n```javascript\nvar line = turf.lineString([\n    [-77.031669, 38.878605],\n    [-77.029609, 38.881946],\n    [-77.020339, 38.884084],\n    [-77.025661, 38.885821],\n    [-77.021884, 38.889563],\n    [-77.019824, 38.892368]\n]);\nvar start = turf.point([-77.029609, 38.881946]);\nvar stop = turf.point([-77.021884, 38.889563]);\n\nvar sliced = turf.lineSlice(start, stop, line);\n\n//addToMap\nvar addToMap = [start, stop, line]\n```\n\nReturns **[Feature][4]<[LineString][1]>** sliced line\n\n[1]: https://tools.ietf.org/html/rfc7946#section-3.1.4\n\n[2]: https://tools.ietf.org/html/rfc7946#section-3.1.2\n\n[3]: https://tools.ietf.org/html/rfc7946#section-3.1.1\n\n[4]: https://tools.ietf.org/html/rfc7946#section-3.2\n\n<!-- This file is automatically generated. Please don't edit it directly. If you find an error, edit the source file of the module in question (likely index.js or index.ts), and re-run \"yarn docs\" from the root of the turf project. -->\n\n---\n\nThis module is part of the [Turfjs project](https://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.\n\n### Installation\n\nInstall this single module individually:\n\n```sh\n$ npm install @turf/line-slice\n```\n\nOr install the all-encompassing @turf/turf module that includes all modules as functions:\n\n```sh\n$ npm install @turf/turf\n```\n","publish_time":1594651737152,"maintainers":[{"name":"smallsaucepan","email":"james@smallsaucepan.com"},{"name":"morgan.herlocker","email":"morganherlocker@gmail.com"},{"name":"twelch","email":"tim.j.welch@gmail.com"},{"name":"jamesmilneruk","email":"jamesmilner22@hotmail.com"},{"name":"rowanwins","email":"rowanwins@yahoo.com.au"},{"name":"tmcw","email":"tom@macwright.com"},{"name":"morganherlocker","email":"morgan.herlocker@gmail.com"},{"name":"tcql","email":"tim.channell@gmail.com"},{"name":"mdfedderly","email":"mdfedderly@mdfedderly.com"}],"_cnpm_publish_time":1594651737152,"dist-tags":{"canary":"3.5.2-alpha.d2c36ee7","latest":"7.4.0","prerelease":"7.1.0-alpha.70"}}