Go to file
Timo Tijhof 99ce7178c0 ext.echo.dm: Remove unreachable lazy-creation code
This boilerplate at the beginning of most files is an anti-pattern from
very early 2011 frontend experiments (I take full blame), where I didn't
understand (or had confidence in) the load order of scripts. I won't
remove it all at once, as that requires careful review of dependencies.

But this one file seemed like low-hanging fruit. The "ext.echo.dm"
contained a file that lazy-created `mw.echo` as empty as empty object,
and `mw.echo.config` as `{ maxPrioritizedActions: 2 }`.

The "ext.echo.init" module loaded on every page already does the same.
Remove this file and depend on that module instead. The same modules
will be downloaded, in the same way, and in the same order as before.

What changes is that the order of execution is now defined instead of
implied, thus making the dm-version of it redundant.

In practice, while fragile, the load order was already consistently
running init before dm. I found this through code coverage analysis in
Chrome DevTools, <https://phabricator.wikimedia.org/F28421786>.

Change-Id: Iaed7cf0e47479ce8ce76aee1bfe479d82b4f61ed
2019-03-19 20:16:37 +00:00
db_patches Remove notification_bundle_display_hash 2019-03-06 10:29:05 -08:00
i18n Localisation updates from https://translatewiki.net. 2019-03-18 23:07:20 +01:00
images Unify BetaFeatures SVG screenshot markup 2017-12-19 09:01:12 -08:00
includes Use ::class on \DatabaseUpdater::addPostDatabaseUpdateMaintenance 2019-03-15 19:28:29 +01:00
maintenance Remove notification_bundle_base 2019-03-04 13:22:17 -08:00
modules ext.echo.dm: Remove unreachable lazy-creation code 2019-03-19 20:16:37 +00:00
scripts Remove obsolete scripts/generatecss.php 2018-09-09 17:07:26 -07:00
tests Disable DiscussionParserTest until we can figure out why it broke 2019-03-15 14:45:23 -04:00
.eslintrc.json build: Set "root": true, in .eslintrc.json 2018-12-17 18:54:51 -08:00
.gitignore Remove Ruby browser tests 2017-12-20 12:29:01 +01:00
.gitreview Whoops, track not trace 2016-10-24 17:02:28 -07:00
.mailmap
.phpcs.xml phpcs: exclude the vendor folder 2018-12-27 21:32:39 +00:00
.stylelintrc.json build: Update linters 2018-02-04 21:23:28 +00:00
CODE_OF_CONDUCT.md build: Updating mediawiki/mediawiki-codesniffer to 22.0.0 2018-09-03 01:46:10 +00:00
composer.json build: Updating mediawiki/mediawiki-codesniffer to 24.0.0 2019-02-06 13:01:32 +00:00
COPYING
Echo.alias.php Remove U+200E (LRM) from comments 2018-09-24 22:15:51 +02:00
echo.sql Remove notification_bundle_display_hash 2019-03-06 10:29:05 -08:00
extension.json ext.echo.dm: Remove unreachable lazy-creation code 2019-03-19 20:16:37 +00:00
Gruntfile.js build: Update eslint-config-wikimedia to 0.10.1 2019-02-06 01:42:53 +00:00
jsduck.external.js jsduck: Remove custom @source tag 2016-09-21 00:51:46 +01:00
jsduck.json Add JSDuck support and fix errors 2016-05-11 14:07:12 -07:00
jsduck_custom_tags.rb jsduck: Remove custom @source tag 2016-09-21 00:51:46 +01:00
Makefile Remove obsolete scripts/generatecss.php 2018-09-09 17:07:26 -07:00
package.json build: Update eslint-config-wikimedia to 0.10.1 2019-02-06 01:42:53 +00:00
RELEASE_NOTES BREAKING CHANGE: Use ISO 8601 for 'ts' in cross-wiki summary. 2016-07-27 17:00:05 -04:00