title: .Net Core 2.0 Publish Error Angular SPA
body: <p>I am having an issue when publishing my .Net Core 2.0 Angular SPA from Visual Studio 2017 Community. The site compiles and runs fine through the debugger.</p>
  
  <p>When I try to publish (to ftp) I get the following error;</p>
  
  <blockquote>
    <p>The command "node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod" exited with code 1.   </p>
  </blockquote>
  
  <p>If I then run 'webpack --config ./project1/web' on the package manager console i get the error;</p>
  
  <blockquote>
    <p>webpack : Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
    At line:1 char:1
    + webpack --config ./project1/webpack.config.vendor.js
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : NotSpecified: (Invalid configu...the API schema.:String) [], RemoteException
        + FullyQualifiedErrorId : NativeCommandError</p>
  </blockquote>
  
  <p>Any ideas on how to rectify this please?</p>
  
  <p>I am running node 5.6.0 and the webpack in my package.json is;</p>
  
  <pre><code>"webpack": "3.10.0",
  "webpack-hot-middleware": "2.21.0",
  "webpack-merge": "4.1.1",
  </code></pre>