Skip to content

Point on feature final #216

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

Newmanjack
Copy link

These changes aim to implement and test a new feature called pointOnFeature, which returns a GeoJSON Feature guaranteed to be on the surface of the input feature. This implementation replicates Turf.js functionality and supports multiple geometry types.

@lukas-h lukas-h linked an issue Apr 4, 2025 that may be closed by this pull request
Copy link
Member

@lukas-h lukas-h left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found a lot of potential to share code with already existing functions of this lib. Can you check that out? :)

@Newmanjack Newmanjack force-pushed the point_on_feature_final branch from a926fb6 to 1dfdb72 Compare April 10, 2025 23:51
…ling.

- Replace custom implementations with existing specialized modules
- Use turf_pip package directly for point-in-polygon checks
- Use turf_centroid, turf_midpoint, turf_area and turf_length libraries
- Make function non-nullable with proper error handling
- Update var to final in benchmark file and across codebase
- Update tests to work with geodesic midpoint calculations
- Improve documentation and code quality
This reverts changes made in commits:
- 41bfee5
- a343ee7

These coordinate conversion features will be handled in a separate PR (oWSG84_and_toMercator_unit)
@Newmanjack Newmanjack requested a review from lukas-h April 16, 2025 04:25
@Newmanjack Newmanjack requested a review from aardrop April 30, 2025 05:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pointOnFeature
3 participants