main

mattermost/focalboard

Last updated at: 29/12/2023 09:38

webpack.prod.js

TLDR

The webpack.prod.js file configures the webpack settings for the production environment. It merges the common configuration from webpack.common.js and adds additional settings for production, such as minifying the output and using the Terser plugin.

Methods

There are no methods in this file.

Classes

There are no classes in this file.

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
const merge = require('webpack-merge');
const TerserPlugin = require('terser-webpack-plugin');

const makeCommonConfig = require('./webpack.common.js');

const commonConfig = makeCommonConfig();

const config = merge.merge(commonConfig, {
    mode: 'production',
    optimization: {
        minimize: true,
        minimizer: [new TerserPlugin({extractComments: false})],
    },
});

module.exports = [
    merge.merge(config, {
    }),
];