Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-17 12:07:48 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-17 12:07:48 +0300
commit5bd24a54ef4ce3a38a860eb53b66d062c2382971 (patch)
tree5f5e65571dfcb2c62c27600ee7655dec4b44c923 /config/webpack.vendor.config.js
parent74673d04d25ffed35cbcf17cd42969bed0a4e705 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'config/webpack.vendor.config.js')
-rw-r--r--config/webpack.vendor.config.js71
1 files changed, 71 insertions, 0 deletions
diff --git a/config/webpack.vendor.config.js b/config/webpack.vendor.config.js
new file mode 100644
index 00000000000..bddbf067d7c
--- /dev/null
+++ b/config/webpack.vendor.config.js
@@ -0,0 +1,71 @@
+const path = require('path');
+const webpack = require('webpack');
+const vendorDllHash = require('./helpers/vendor_dll_hash');
+
+const ROOT_PATH = path.resolve(__dirname, '..');
+
+const dllHash = vendorDllHash();
+const dllCachePath = path.join(ROOT_PATH, `tmp/cache/webpack-dlls/${dllHash}`);
+const dllPublicPath = `/assets/webpack/dll.${dllHash}/`;
+
+module.exports = {
+ mode: 'development',
+ resolve: {
+ extensions: ['.js'],
+ },
+
+ context: ROOT_PATH,
+
+ entry: {
+ vendor: [
+ 'jquery',
+ 'pdfjs-dist/build/pdf',
+ 'pdfjs-dist/build/pdf.worker.min',
+ 'sql.js',
+ 'core-js',
+ 'echarts',
+ 'lodash',
+ 'underscore',
+ 'vuex',
+ 'pikaday',
+ 'vue/dist/vue.esm.js',
+ 'at.js',
+ 'jed',
+ 'mermaid',
+ 'katex',
+ 'three',
+ 'select2',
+ 'moment',
+ 'aws-sdk',
+ 'sanitize-html',
+ 'bootstrap/dist/js/bootstrap.js',
+ 'sortablejs/modular/sortable.esm.js',
+ 'popper.js',
+ 'apollo-client',
+ 'source-map',
+ 'mousetrap',
+ ],
+ },
+
+ output: {
+ path: dllCachePath,
+ publicPath: dllPublicPath,
+ filename: '[name].dll.bundle.js',
+ chunkFilename: '[name].dll.chunk.js',
+ library: '[name]_[hash]',
+ },
+
+ plugins: [
+ new webpack.DllPlugin({
+ path: path.join(dllCachePath, '[name].dll.manifest.json'),
+ name: '[name]_[hash]',
+ }),
+ ],
+
+ node: {
+ fs: 'empty', // sqljs requires fs
+ setImmediate: false,
+ },
+
+ devtool: 'cheap-module-source-map',
+};