const CleanWebpackPlugin = require('clean-webpack-plugin');
const path = require('path');

module.exports = {
	mode: 'production',
	entry: {
		main: './src/js/main.js',
		portfolio: './src/js/portfolio.js'
	},
	plugins: [
		new CleanWebpackPlugin(['dist/js'])
	],
	output: {
		filename: '[name].js',
		path: path.resolve(__dirname, 'dist/js')
	}
};

const CleanWebpackPlugin = require('clean-webpack-plugin');
const path = require('path');

module.exports = {
	mode: 'production',
	entry: {
		main: './src/js/main.js',
		portfolio: './src/js/portfolio.js'
	},
	plugins: [
		new CleanWebpackPlugin(['dist/js'])
	],
	output: {
		filename: '[name].[contenthash].js',
		path: path.resolve(__dirname, 'dist/js')
	}
};

Add content hash to file name of bundles
Add content hash to file name of bundles
