Opened 5 months ago

Closed 5 months ago

Last modified 2 months ago

#31493 closed Cleanup/optimization (fixed)

Replace var usage with const and let keywords in JavaScript.

Reported by: Jon Dufresne Owned by: nobody
Component: contrib.admin Version: master
Severity: Normal Keywords:
Cc: Adam (Chainz) Johnson Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Change History (9)

comment:2 Changed 5 months ago by Adam (Chainz) Johnson

Cc: Adam (Chainz) Johnson added
Triage Stage: UnreviewedAccepted

comment:3 Changed 5 months ago by Adam (Chainz) Johnson

Additionally, whilst we don't officially support IE11 since that commit, https://caniuse.com/#search=const and https://caniuse.com/#search=let show it has support with only caveats for loops, so I expect most things should continue to function there.

comment:4 Changed 5 months ago by Carlton Gibson <carlton@…>

Resolution: fixed
Status: newclosed

In 5d37cc70:

Fixed #31493 -- Replaced var with const and let keywords in JavaScript.

The eslint configuration and the admin script compress.py have been
updated for ES6.

The unused fallback of globals.django in jquery.init.js was removed. It
is always included before jsi18n-mocks.test.js and it always sets the
global value.

comment:5 Changed 5 months ago by Carlton Gibson <carlton@…>

In 7271c8de:

Refs #31493 -- Changed IIFE to ES6 blocks.

comment:6 Changed 3 months ago by Carlton Gibson <carlton@…>

In 2afa61e:

Refs #31493 -- Replaced var with const/let in documentation JS.

comment:7 Changed 3 months ago by Carlton Gibson <carlton.gibson@…>

In 6ed4a9b:

[3.1.x] Refs #31493 -- Replaced var with const/let in documentation JS.

Backport of 2afa61e7d99b2ff2656dc64b6e28db88baf786a4 from master

comment:8 Changed 3 months ago by Carlton Gibson <carlton.gibson@…>

In af2e95b0:

[3.0.x] Refs #31493 -- Replaced var with const/let in documentation JS.

Backport of 2afa61e7d99b2ff2656dc64b6e28db88baf786a4 from master

Co-authored-by: Carlton Gibson <carlton.gibson@…>

comment:9 Changed 2 months ago by GitHub <noreply@…>

In b23216d:

Refs #31493 -- Replaced var with const and let in JavaScriptCatalog template.

Note: See TracTickets for help on using tickets.
Back to Top