title: webpack: configuration.entry should be an non-empty object
body: <p><code>serverless deploy</code> is throwing this error with latest webpack verstion.</p>
  
  <pre><code>Serverless: Bundling with Webpack...
  
    Webpack Options Validation Error -----------------------
  
    WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
   - configuration.entry should be a non-empty object.
  </code></pre>
  
  <p>webpack.config.js</p>
  
  <pre><code>
      const path = require('path');
      const slsw = require('serverless-webpack');
      // var nodeExternals = require('webpack-node-externals')
  
      module.exports = {
        mode: slsw.lib.webpack.isLocal ? 'development' : 'production',
        entry: slsw.lib.entries,
        // externals: [nodeExternals()],
        devtool: 'source-map',
        resolve: {
          extensions: ['.js', '.jsx', '.json', '.ts', '.tsx'],
        },
        output: {
          libraryTarget: 'commonjs',
          path: path.join(__dirname, '.webpack'),
          filename: '[name].js',
        },
        target: 'node',
        module: {
          rules: [
            // all files with a `.ts` or `.tsx` extension will be handled by `ts-loader`
            { test: /\.tsx?$/, loader: 'ts-loader' },
          ],
        },
      };
  
  </code></pre>
  
  <p>package.json</p>
  
  <pre><code>
      "serverless": "^1.72.0",
      "serverless-aws-documentation": "^1.1.0",
      "serverless-dynamodb-local": "^0.2.39",
      "serverless-iam-roles-per-function": "^2.0.2",
      "serverless-offline": "^6.4.0",
      "serverless-reqvalidator-plugin": "^1.0.3",
      "serverless-s3-local": "^0.6.2",
      "serverless-webpack": "^5.3.2",
      "ts-loader": "^7.0.5",
      "typescript": "^3.9.5",
      "webpack": "^4.43.0"
  
  </code></pre>
  
  <p>there's something related here: <a href="https://github.com/serverless-heaven/serverless-webpack/issues/372" rel="nofollow noreferrer">https://github.com/serverless-heaven/serverless-webpack/issues/372</a></p>
  
  <p>serverless.yml is very standard and was working with older webpack versions.
  Not expert in webpack here, any help much appreciated. </p>