Answers for "what is webpack"

0

install webpack

npm install --save-dev webpack
# or specific version
npm install --save-dev webpack@<version>
Posted by: Guest on April-25-2020
0

what is webpack.js

// Based on the provided configuration (webpack.config.js), 
// webpack starts from the entry points and resolves each module it 
// encounters while constructing the dependency graph

// entry points
// the entry point is the module that webpack uses to start building its internal dependency graph.
entry: {
            'app': glob.sync('./vendor/**/*.js').concat(['./js/app.js'])
        },
          
          
// output point
// the output property instructs webpack where to emit the bundle(s) and what name to use for the file(s)
output: {
            filename: '[name].js',
            path: path.resolve(__dirname, '../priv/static/js'),
            publicPath: '/js/'
        },
          
// dependency graph
// From the entry point, webpack will configure a set of nodes connected to one 
// another as dependencies and will compile that to the output point
Posted by: Guest on May-11-2021
-1

webpack

npm install webpack
Posted by: Guest on October-27-2021

Code answers related to "what is webpack"

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language