Skip to content

JS: Avoid using global vars in documentation examples #13195

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

Merged
merged 1 commit into from
May 30, 2023

Conversation

asgerf
Copy link
Contributor

@asgerf asgerf commented May 17, 2023

Fixes #13175

Flow through global variables is less precise than for locals, so the barrier used in the example doesn't work unless the code is put into a function.

@asgerf asgerf added JS no-change-note-required This PR does not need a change note labels May 17, 2023
@github-actions github-actions bot added documentation and removed JS labels May 17, 2023
@asgerf asgerf requested a review from erik-krogh May 30, 2023 13:24
@asgerf asgerf merged commit d7f747e into github:main May 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation no-change-note-required This PR does not need a change note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using flow labels JavaScript tutorial example queries don't work
2 participants