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

Add point_count_abbreviated property to clustered features #955

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Oreilles
Copy link

Add point_count_abbreviated property to clustered features to improve consistency with clusters generated by supercluster.
The formula used is taken from supercluster/index.js#L377-L379:

    const abbrev =
        count >= 10000 ? `${Math.round(count / 1000)  }k` :
        count >= 1000 ? `${Math.round(count / 100) / 10  }k` : count;

@e-n-f
Copy link
Contributor

e-n-f commented Nov 14, 2022

Could you please make this PR against https://github.com/felt/tippecanoe instead? The mapbox repo is essentially unmaintained now.

@Oreilles
Copy link
Author

Done 👍

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