How does webpack package multiple js files separately?

  node.js, question

图片描述

There are many files in src directory. If you use webpack, is there any way to make dist directory output one by one instead of packing all the files into the same js inside?

Fill in multiple entry files:

module.exports = {
 entry: {
 bundle1: './addr.js',
 bundle2: './backward.js'
 .......
 },
 output: {
 filename: '[name].js'
 bracket
 };