summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClement Ho <ClemMakesApps@gmail.com>2018-02-21 20:54:18 -0600
committerClement Ho <ClemMakesApps@gmail.com>2018-02-21 20:54:18 -0600
commit0f596d9173d0f1e14c4ac7e6058089ea87724099 (patch)
treeaa9a46267486bb56ade7d760b54781a3bbf64ccb
parent2a3116690f4213814afa6010c626973dce848ad9 (diff)
downloadgitlab-ce-webpack-autoinclude.tar.gz
Use const instead of letwebpack-autoinclude
-rw-r--r--config/webpack.config.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/config/webpack.config.js b/config/webpack.config.js
index 22a8d2bf382..94ff39485fb 100644
--- a/config/webpack.config.js
+++ b/config/webpack.config.js
@@ -30,9 +30,9 @@ var dispatcher = fs.readFileSync(path.join(ROOT_PATH, 'app/assets/javascripts/di
var dispatcherChunks = dispatcher.match(/(?!import\(')\.\/pages\/[^']+/g);
function generateAutoEntries(path, prefix = '.') {
- let chunkPath = path.replace(/\/index\.js$/, '');
+ const chunkPath = path.replace(/\/index\.js$/, '');
if (!dispatcherChunks.includes(`${prefix}/${chunkPath}`)) {
- let chunkName = chunkPath.replace(/\//g, '.');
+ const chunkName = chunkPath.replace(/\//g, '.');
autoEntries[chunkName] = `${prefix}/${path}`;
}
}