File tree Expand file tree Collapse file tree 3 files changed +12
-13
lines changed
Expand file tree Collapse file tree 3 files changed +12
-13
lines changed Original file line number Diff line number Diff line change 11# 1.2.0
22- Use robust-predicates library for some calcs
3+ - Refactor logic to reduce package size and improve performance
34- Move to vitest
45
56# 1.1.0
Original file line number Diff line number Diff line change @@ -52,16 +52,16 @@ While `point-in-polygon` is slightly faster in most cases it does not support po
5252
5353````
5454// For a point in a much larger geometry (700+ vertices)
55- point-in-poly-hao x 348,426 ops/sec ±3.04 % (84 runs sampled)
56- point-in-polygon x 290,308 ops/sec ±2.53 % (90 runs sampled)
57- robust-point-in-polygon x 279,963 ops/sec ±0.66 % (88 runs sampled)
55+ point-in-poly-hao x 381,184 ops/sec ±0.80 % (87 runs sampled)
56+ point-in-polygon x 285,734 ops/sec ±1.33 % (91 runs sampled)
57+ robust-point-in-polygon x 267,738 ops/sec ±0.78 % (93 runs sampled)
5858````
5959
6060````
6161// For a point in bounding box check
62- point-in-poly-hao x 23,514,349 ops/sec ±1.71 % (86 runs sampled)
63- point-in-polygon x 27,979,131 ops/sec ±2.47 % (86 runs sampled)
64- robust-point-in-polygon x 24,954,850 ops/sec ±1.77 % (88 runs sampled)
62+ point-in-poly-hao x 25,822,227 ops/sec ±2.87 % (86 runs sampled)
63+ point-in-polygon x 30,321,920 ops/sec ±2.14 % (91 runs sampled)
64+ robust-point-in-polygon x 26,708,560 ops/sec ±1.13 % (91 runs sampled)
6565````
6666
6767### Algorithm
Original file line number Diff line number Diff line change 11{
22 "name" : " point-in-polygon-hao" ,
3- "version" : " 1.1 .0" ,
3+ "version" : " 1.2 .0" ,
44 "type" : " module" ,
55 "description" : " A point in polygon based on the paper Optimal Reliable Point-in-Polygon Test and Differential Coding Boolean Operations on Polygons" ,
6- "main" : " dist/pointInPolygon.js " ,
6+ "main" : " dist/pointInPolygon.mjs " ,
77 "module" : " dist/pointInPolygon.mjs" ,
88 "unpkg" : " dist/pointInPolygon.min.js" ,
99 "jsdelivr" : " dist/pointInPolygon.min.js" ,
1414 "test" : " vitest"
1515 },
1616 "dependencies" : {
17- "robust-predicates" : " ^3.0.2" ,
18- "vitest" : " ^2.1.6"
17+ "robust-predicates" : " ^3.0.2"
1918 },
2019 "devDependencies" : {
2120 "@rollup/plugin-buble" : " ^0.21.3" ,
22- "@turf/boolean-point-in-polygon" : " ^6.0.1" ,
23- "ava" : " ^3.15.0" ,
2421 "benchmark" : " ^2.1.4" ,
2522 "eslint" : " ^5.15.3" ,
2623 "eslint-config-mourner" : " ^3.0.0" ,
2926 "point-in-polygon" : " ^1.0.1" ,
3027 "robust-point-in-polygon" : " ^1.0.3" ,
3128 "rollup" : " ^1.7.0" ,
32- "rollup-plugin-terser" : " ^4.0.4"
29+ "rollup-plugin-terser" : " ^4.0.4" ,
30+ "vitest" : " ^2.1.6"
3331 },
3432 "keywords" : [
3533 " point-in-polygon" ,
You can’t perform that action at this time.
0 commit comments