diff --git a/.gitignore b/.gitignore index c02c108aa..eafa360eb 100644 --- a/.gitignore +++ b/.gitignore @@ -4,7 +4,6 @@ **/dist **/lib **/src-gen -**/webpack.config.js **/gen-webpack.config.js **/plugins **/tsconfig.tsbuildinfo diff --git a/applications/electron/webpack.config.js b/applications/electron/webpack.config.js new file mode 100644 index 000000000..8bd02af31 --- /dev/null +++ b/applications/electron/webpack.config.js @@ -0,0 +1,17 @@ +/** + * This file can be edited to customize webpack configuration. + * To reset delete this file and rerun theia build again. + */ +// @ts-check +const config = require('./gen-webpack.config.js'); + +/** + * Expose bundled modules on window.theia.moduleName namespace, e.g. + * window['theia']['@theia/core/lib/common/uri']. + * Such syntax can be used by external code, for instance, for testing. +config.module.rules.push({ + test: /\.js$/, + loader: require.resolve('@theia/application-manager/lib/expose-loader') +}); */ + +module.exports = config; \ No newline at end of file