Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 16285 | Rev 16649 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 16285 Rev 16644
Línea 3... Línea 3...
3
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
3
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
4
const TerserPlugin = require("terser-webpack-plugin");
4
const TerserPlugin = require("terser-webpack-plugin");
Línea 5... Línea 5...
5
 
5
 
6
// Add paths while bundling
6
// Add paths while bundling
Línea 154... Línea 193...
154
}
193
};
155
 
194
 
Línea 156... Línea 195...
156
// change active path here
195
// change active path here
157
const currentPath = paths.mobileChat;
196
const currentPath = paths.groupTypes;
158
 
197
 
159
module.exports = {
198
module.exports = {
160
	entry: currentPath.entry,
199
  entry: currentPath.entry,
161
	output: {
200
  output: {
162
		path: currentPath.output,
201
    path: currentPath.output,
163
		filename: currentPath.filename,
202
    filename: currentPath.filename,
164
	},
203
  },
165
	watch: isDevelopment ? true : false,
204
  watch: isDevelopment ? true : false,
166
	mode: isDevelopment ? 'development' : 'production',
205
  mode: isDevelopment ? "development" : "production",
167
	resolve: {
206
  resolve: {
168
		extensions: ['.js', '.jsx', '.scss'],
207
    extensions: [".js", ".jsx", ".scss"],
169
	},
208
  },
170
	module: {
209
  module: {
171
		rules: [
210
    rules: [
172
			{
211
      {
173
				test: /(js|jsx)$/,
212
        test: /(js|jsx)$/,
174
				use: ['babel-loader'],
213
        use: ["babel-loader"],
175
				exclude: /node_modules/,
214
        exclude: /node_modules/,
176
			},
215
      },
177
			{
216
      {
178
				test: /\.css$/i,
217
        test: /\.css$/i,
179
				use: [MiniCssExtractPlugin.loader, 'css-loader'],
218
        use: [MiniCssExtractPlugin.loader, "css-loader"],
180
			},
219
      },
181
			{
220
      {
182
				test: /\.module\.s(a|c)ss$/,
221
        test: /\.module\.s(a|c)ss$/,
183
				use: [
222
        use: [
184
					MiniCssExtractPlugin.loader,
223
          MiniCssExtractPlugin.loader,
185
					{
224
          {
186
						loader: 'css-loader',
225
            loader: "css-loader",
187
						options: {
226
            options: {
188
							modules: {
227
              modules: {
189
								localIdentName: '[local]--[hash:base64:5]',
228
                localIdentName: "[local]--[hash:base64:5]",
190
							},
229
              },
191
							sourceMap: isDevelopment,
230
              sourceMap: isDevelopment,
192
						},
231
            },
193
					},
232
          },
194
					{
233
          {
195
						loader: 'sass-loader',
234
            loader: "sass-loader",
196
						options: {
235
            options: {
197
							sourceMap: isDevelopment,
236
              sourceMap: isDevelopment,
198
						},
237
            },
199
					},
238
          },
200
				],
239
        ],
201
			},
240
      },
202
			{
241
      {
203
				test: /\.s(a|c)ss$/,
242
        test: /\.s(a|c)ss$/,
204
				exclude: /\.module.(s(a|c)ss)$/,
243
        exclude: /\.module.(s(a|c)ss)$/,
205
				use: [
244
        use: [
206
					MiniCssExtractPlugin.loader,
245
          MiniCssExtractPlugin.loader,
207
					'css-loader',
246
          "css-loader",
208
					{
247
          {
209
						loader: 'sass-loader',
248
            loader: "sass-loader",
210
						options: {
249
            options: {
211
							sourceMap: isDevelopment,
250
              sourceMap: isDevelopment,
212
						},
251
            },
213
					},
252
          },
214
				],
253
        ],
215
			},
254
      },
216
		],
255
    ],
217
	},
256
  },
218
	plugins: [
257
  plugins: [
219
		new MiniCssExtractPlugin({
258
    new MiniCssExtractPlugin({
220
			filename: '[name].css',
259
      filename: "[name].css",
221
			chunkFilename: '[id].css',
260
      chunkFilename: "[id].css",
222
		}),
261
    }),
223
	],
262
  ],
224
	optimization: {
263
  optimization: {
225
		minimizer: [
264
    minimizer: [
226
			new TerserPlugin({
265
      new TerserPlugin({
227
				extractComments: false,
266
        extractComments: false,
228
			}),
267
      }),