{"name":"@turf/line-slice","version":"6.2.0-alpha.1","keywords":["turf","linestring","geojson","linear","reference","line","distance"],"author":{"name":"Turf Authors"},"license":"MIT","_id":"@turf/line-slice@6.2.0-alpha.1","homepage":"https://github.com/Turfjs/turf","bugs":{"url":"https://github.com/Turfjs/turf/issues"},"dist":{"shasum":"686628312925993231be74b5e6bffce132173771","tarball":"http://registry-npm.ywwl.com/@turf/line-slice/download/@turf/line-slice-6.2.0-alpha.1.tgz","fileCount":7,"integrity":"sha512-84Wu4mOToTHvUw374FFUsTiNtFxResoe+7rZnHm6/PQXRbE/p5FHy0SernnA/isnI9Vw7nj8zro+fSJqPAoBhQ==","signatures":[{"sig":"MEUCIQCnj7BWPSg4PaToRevLXd5Tom+zS+RoVyMZqYEmrsWiswIgc+mKKboh49lsy/wQw2jMpeMDdClMY5SK62vh3htCvXE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":10729,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJefUQICRA9TVsSAnZWagAApB0P/iTPq3ug3WB72l+yGGtg\nBJuHsqY7PKqCeuPZguSmWwRWDxMn6zhv6bD4zRG7xxjaWM2Tc+h0GALv0M6t\nirGiMRacJpPqeVBrJOPgwcEVde+dkauPQldzyDAHQW7ELmwZTUUkPYzLDqJ7\nTVQcouHwnN1qlWviuiAIULMCM1mFJtDwO6sWq0kzwYXZxMpXeE5HwzFm191z\nBweUmpsQHC4EFTmj2Yy4B0mT0Z4c/HkC+tYiyM2dSiBkfeYZI9qjMdtYK7gs\nIn/4T1xF110YiZ2Qbzd8N1c8VINO4FjTkBlrIlhejPgaXBODK+mTz5MiHNUO\n+M8BSQKl0XgSWr/K551nOhuo65uf/H/JToD1KvAlcqAO+V8IHd1gqxrmrKLf\nwcBLJN5DB5X0NoYkobQA0ShUDyoIVM29rpl71sviYtsNrUUs8AQf1PVr5uph\nk1huUWcZRqQWKaOHA6QphXUZI1epCsj1vX6m6S7CPGLUjnb5vm1njRBqk+hT\nnHMMz/eW8GIBbRSqPavRUTThSN7MjFG2Cn3qGZHvulnoiOUKLH1uwM7DjH+m\nrmvfskWjZ8b3nGjbje/3auqzV+yK/7tn/3vs6Ob25jNZl0CXzqYacTcXm4X7\ne2mbbOdnzFK4tVwkVw/m4pzQD8KbEy7/gpUXU/XVzTe36U6AkrhyaLIwxuN+\niJpS\r\n=fbhe\r\n-----END PGP SIGNATURE-----\r\n","size":3106,"noattachment":false,"key":"/@turf/line-slice/-/@turf/line-slice-6.2.0-alpha.1.tgz"},"main":"dist/js/index.js","types":"index.d.ts","module":"dist/es/index.js","gitHead":"fc519c045a8931c1e14eab9160a7e28391f8da02","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.1","@turf/invariant":"^6.2.0-alpha.1","@turf/nearest-point-on-line":"^6.2.0-alpha.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tape":"*","rollup":"*","benchmark":"*","@turf/truncate":"^6.2.0-alpha.1","load-json-file":"*","write-json-file":"*"},"_npmOperationalInternal":{"tmp":"tmp/line-slice_6.2.0-alpha.1_1585267720189_0.827410439333055","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":1585267720331,"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":1585267720331,"dist-tags":{"canary":"3.5.2-alpha.d2c36ee7","latest":"7.4.0","prerelease":"7.1.0-alpha.70"}}