Skip to content
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

Merge of #11 - Allow customisation by transformers #16

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

nrenner
Copy link

@nrenner nrenner commented Mar 9, 2021

This is a merge of PR #11 to current master.

From review comments:

  1. rebase the code onto current master and fix the merge conflicts

Done in 5c88fd4.

the ; is superfluous here, right? (as it's the end of the mapFeature function definition)
2. modify the logic in the defaults helper method, so that it matches ES6's Object.assign (just removing the if condition should do the trick), rename it to assign (or so) and use it also override the default options at the very beginning of the code

Done in 95f4bf7, I kept the if condition but reversed the logic to match Object.assign (see e.g. MDN polyfill) and options init.

I also added two additional changes, to not set feature name, etc. on every trkpt/rtept (46c5e84) and to order rte before trk (4199a90).

  1. document the new functionality in the project's readme, i.e. the new options (gpx.* flags and transforms) and maybe a dedicated chapter about how to use the transforms with one or two examples.

Still to be done, maybe later, but also wouldn't mind if someone else did.

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.

2 participants