Skip to content

RD-1718 Enable terrain on render if style already loaded#321

Open
katemihalikova wants to merge 1 commit intonextfrom
RD-1718
Open

RD-1718 Enable terrain on render if style already loaded#321
katemihalikova wants to merge 1 commit intonextfrom
RD-1718

Conversation

@katemihalikova
Copy link
Contributor

Objective

Fix a bug that prevented terrain being turned on immediately

Description

Using "render" event instead of "moveend" if style is loaded.

Acceptance

Manual testing

Checklist

  • I have added relevant info to the CHANGELOG.md

};

this.once("load", () => {
this.once(this.style._loaded ? "render" : "load", () => {

Choose a reason for hiding this comment

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

It looks like a solid fix. But will it work in case that style is done loading but data are still loading?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants