-
Notifications
You must be signed in to change notification settings - Fork 945
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
turf-voronoi - retain properties from points #2421
Conversation
Is this repo alive? What do I have to do to get the review? |
Hi @maral. Yes the repo is still alive, and working toward a v7 release. Everyone here is doing their best so apologies we haven't gotten to your PR yet. No one wants to see your work go to waste. Will take a look for you and get this in when we can. Cheers |
Thanks for the response, appreciate it. I didn't want to be rude, but I kept checking on the PR every now and then, I guess I could have asked earlier :) Keep up the good work! |
All good. Took a look at the PR and have an idea would like your thoughts on. Rather than JSON stringify + parse to deep copy the props, what if we were to make cloneProperties() available outside turf-clone and use that? Might head off performance / memory problems if someone throws in a point with a million properties on it. Also happy to submit this as is and revisit the performance if / when someone runs into a problem. |
Thanks! Of course, I would rather use |
Hi @smallsaucepan, I finally found time to finalize this and I am not sure what the best approach is here - in CONTRIBUTING, there is this little sentence:
If I used |
Hi @maral. Keeping it to one function per module is generally true and been a worthwhile design goal. It's probably overkill though to separate the prop cloning into it's own module, especially as it's a clear subset of cloning a whole object. Making it a named export (as you have) is a good balance. Will review and try to get it merged. |
Resolves #1450, voronoi now retains properties from the geoJson points as default, no option required.
npm test
at the sub modules where changes have occurred.npm run lint
to ensure code style at the turf module level.