app: Prepare JS files for consumption by webpack.

This commit prepares the frontend code to be consumed by webpack.

It is a hack: In theory, modules should be declaring and importing the
modules they depend on and the globals they expose directly.

However, that requires significant per-module work, which we don't
really want to block moving our toolchain to webpack on.

So we expose the modules by setting window.varName = varName; as
needed in the js files.
This commit is contained in:
Armaan Ahluwalia
2018-05-28 11:34:36 +05:30
committed by Tim Abbott
parent b10822efcf
commit 6d255efe4c
163 changed files with 180 additions and 1 deletions

View File

@@ -84,3 +84,4 @@ return exports;
if (typeof module !== 'undefined') {
module.exports = settings_ui;
}
window.settings_ui = settings_ui;