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 a function for getting zoom range #780

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

Conversation

joshkel
Copy link
Contributor

@joshkel joshkel commented Sep 4, 2023

This adds a function, getZoomedScaleBounds, to act as a counterpart to getInitialScaleBounds (getting the scale ranges after zoom rather than before) and zoomScale (reading, rather than writing, each scale's zoom).

A question for code review: Is it okay to return the internal object directly, or should I return a new object to ensure that it can't be mutated?

Update types for getInitialScaleBounds - its implementation shows that it may return undefined.
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.

None yet

1 participant