title: How to bundle assets folder fully - webpack
body: <p>I am building a Web Application using MEAN stack.</p>
  
  <p>I am using webpack to bundle my files.</p>
  
  <p>In my project, I have two folders called 1.public/assets (in this assets folder I have separate folders called CSS, js, etc.. which contains various js and CSS.</p>
  
  <p>and I have a folder called 2.client (in this I have my AngularJs code like controllers.js, services.js)</p>
  
  <p>I am using webpack to bundle my client code.</p>
  
  <pre><code>const path = require('path');
  const glob = require('glob');
  const CleanWebpackPlugin = require('clean-webpack-plugin');
  // const CopyWebpackPlugin = require('copy-webpack-plugin');
  
  
  const outputDirectory = 'dist';
  
  module.exports = {
    mode: 'development',
    target: 'web',
    entry: {
      app: glob.sync('./client/*.js'),
    },
    output: {
      path: path.resolve(__dirname, outputDirectory),
      filename: '[name].bundle.js',
    },
    module: {
      rules: [
        {
          test: /\.js$/,
          exclude: /node_modules/,
          use: {
            loader: 'babel-loader',
            query: {
              presets: ['env', 'stage-0'],
            },
          },
        },
        {
          test: /\.css$/,
          use: ['style-loader', 'css-loader'],
        },
        {
          test: /\.(png|woff|woff2|eot|ttf|svg|jpg)$/,
          loader: 'url-loader?limit=100000',
        },
      ],
    },
    devServer: {
      port: 3005,
      open: false,
      disableHostCheck: true,
      proxy: {
        '/': 'http://localhost:8005',
      },
    },
    plugins: [
      new CleanWebpackPlugin([outputDirectory]),
      // new CopyWebpackPlugin([
      //   { from: 'public/assets' },
      // ]),
    ],
  
  };
  </code></pre>
  
  <p>I am just bundling my client folder and compiling that into app.bundle.js, 
  How to compile assets? </p>
  
  <p>NOTE: I am using AngularJs v1.</p>