Some ideas (courtesy @Chlod and @TheDJ):
~~[] functions to classes~~ striking for now, high effort
[x] `var` to `const`/`let`
[] `$.Deferred()` to `Promise()` ([[https://codesearch-beta.wmcloud.org/extensions/?q=%5C%24%5C.Deferred&files=&excludeFiles=i18n&repos=Extension%3APageTriage| 3 files]])
- Note: mw.Api uses jQuery.Promise, resulting in [[ https://codesearch-beta.wmcloud.org/extensions/?q=jQuery%5C.Promise&files=%5C.js%24&excludeFiles=i18n&repos=Extension%3APageTriage | even more uses of it ]] than the 3 above. And do we want to start mixing jQuery.Promise and Promise? Maybe not.
[] cleanup of `that = this`, ([[https://codesearch-beta.wmcloud.org/extensions/?q=that+%3D+this&files=&excludeFiles=i18n&repos=Extension%3APageTriage|13 files]])
[] conversion of `function (){}` to `() => {}` ([[https://codesearch-beta.wmcloud.org/extensions/?q=%5C%28+function+%5C%28%5C%29+%5C%7B&files=&excludeFiles=i18n&repos=Extension%3APageTriage |24 files]])
[] `$.when` to `Promise.all()` ([[https://codesearch-beta.wmcloud.org/extensions/?q=%5C%24%5C.when&files=&excludeFiles=i18n&repos=Extension%3APageTriage|4 instances]])
[] concatenation to backticks, e.g. `${string}` interpolation
Split from {T324579}