From e838dd8f7f141de69eba9509c95f848942482a87 Mon Sep 17 00:00:00 2001 From: Matt Fedderly Date: Tue, 6 Aug 2024 11:09:25 -0400 Subject: [PATCH] Small fixes I've found along the way --- packages/turf-line-offset/test.ts | 2 +- packages/turf-point-to-line-distance/README.md | 2 +- packages/turf-point-to-line-distance/index.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/turf-line-offset/test.ts b/packages/turf-line-offset/test.ts index 6efcfa7638..45401b66b6 100644 --- a/packages/turf-line-offset/test.ts +++ b/packages/turf-line-offset/test.ts @@ -55,7 +55,7 @@ test("turf-line-offset - Throws Errors", (t) => { [0, 0], ]); t.throws(() => lineOffset(), /geojson is required/); - t.throws(() => lineOffset(line, /offset is required/)); + t.throws(() => lineOffset(line), /offset is required/); t.end(); }); diff --git a/packages/turf-point-to-line-distance/README.md b/packages/turf-point-to-line-distance/README.md index 37d7ce1e34..81792b28fa 100644 --- a/packages/turf-point-to-line-distance/README.md +++ b/packages/turf-point-to-line-distance/README.md @@ -15,7 +15,7 @@ minimum distance between the point and any segment of the `LineString`. * `options.units` **[string][7]** can be anything supported by turf/convertLength (ex: degrees, radians, miles, or kilometers) (optional, default `"kilometers"`) - * `options.method` **[string][7]** wether to calculate the distance based on geodesic (spheroid) or + * `options.method` **[string][7]** whether to calculate the distance based on geodesic (spheroid) or planar (flat) method. Valid options are 'geodesic' or 'planar'. (optional, default `"geodesic"`) ### Examples diff --git a/packages/turf-point-to-line-distance/index.ts b/packages/turf-point-to-line-distance/index.ts index 290aa70d0d..0bd7b60b48 100644 --- a/packages/turf-point-to-line-distance/index.ts +++ b/packages/turf-point-to-line-distance/index.ts @@ -23,7 +23,7 @@ import { rhumbDistance as getPlanarDistance } from "@turf/rhumb-distance"; * @param {Object} [options={}] Optional parameters * @param {string} [options.units="kilometers"] can be anything supported by turf/convertLength * (ex: degrees, radians, miles, or kilometers) - * @param {string} [options.method="geodesic"] wether to calculate the distance based on geodesic (spheroid) or + * @param {string} [options.method="geodesic"] whether to calculate the distance based on geodesic (spheroid) or * planar (flat) method. Valid options are 'geodesic' or 'planar'. * @returns {number} distance between point and line * @example