-
-
Notifications
You must be signed in to change notification settings - Fork 34.5k
Don't use var in js code #136938
Copy link
Copy link
Closed as not planned
Labels
OS-emscripteninterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)pendingThe issue will be closed if no feedback is providedThe issue will be closed if no feedback is providedtype-refactorCode refactoring (with no changes in behavior)Code refactoring (with no changes in behavior)
Metadata
Metadata
Assignees
Labels
OS-emscripteninterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)pendingThe issue will be closed if no feedback is providedThe issue will be closed if no feedback is providedtype-refactorCode refactoring (with no changes in behavior)Code refactoring (with no changes in behavior)
While reviewing recent js code changes related to WASM / Emscripten I've noticed that there are lots of existing and new
vardeclarations.Good reference: https://javascript.plainenglish.io/why-you-should-never-use-var-again-seriously-447183bd8d62
We should change them to be
letandconst.Related: https://github.com/python/cpython/pull/136837/files
Linked PRs
varin js, useletandconst#136939