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

Prevent uneccessary tile requests going out and being processed on response #151

Merged
merged 5 commits into from
Mar 10, 2018

Conversation

JamesLMilner
Copy link
Contributor

Also stop doing unnecessary work for responses that come back for tiles on previous zoom levels.

<script type="text/javascript" src="../src/Leaflet.VectorGrid.Protobuf.js"></script>-->
<script type="text/javascript" src="https://unpkg.com/leaflet@1.0.3/dist/leaflet.js"></script>
<!-- <script src="https://unpkg.com/leaflet.vectorgrid@1.2.0"></script> -->
<script type="text/javascript" src="./../dist/Leaflet.VectorGrid.bundled.js"></script>
Copy link
Member

Choose a reason for hiding this comment

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

Please note that this will fail "in production", i.e. when merged into the master branch and when a new build is released.

<script type="text/javascript" src="../src/Leaflet.Renderer.Canvas.Tile.js"></script>
<script type="text/javascript" src="../src/Leaflet.VectorGrid.js"></script>
<script type="text/javascript" src="../src/Leaflet.VectorGrid.Protobuf.js"></script>-->
<script type="text/javascript" src="https://unpkg.com/leaflet@1.0.3/dist/leaflet.js"></script>
Copy link
Member

Choose a reason for hiding this comment

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

Upgrade to Leaflet 1.3.1 while we're at it?

Copy link
Member

@IvanSanchez IvanSanchez left a comment

Choose a reason for hiding this comment

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

Copy link
Member

@IvanSanchez IvanSanchez left a comment

Choose a reason for hiding this comment

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

LGTM

@JamesLMilner JamesLMilner changed the title Don't send requests for none current zoom levels Prevent uneccessary tile requests going out and being processed on response Mar 10, 2018
}
}

if (styleOptions instanceof Function) {
styleOptions = styleOptions(feat.properties, coords.z);
Copy link

Choose a reason for hiding this comment

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

feat.type argument missed. See #130 (comment)

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.

3 participants