webpack-contrib/webpack-serve

cli -r options not works multi times

Closed this issue · 2 comments

  • Operating System: win10
  • Node Version: v10.3.0
  • NPM Version: 6.1.0
  • webpack Version: 4.17.2
  • webpack-serve Version: 2.0.2

Actual Behavior

Error: Flags were specified with invalid values:

  --require  must be set to a string

Please check the command executed.

Code

npx webpack-serve -r @babel/register -r esm

I look at the schema file, found the 'require' options type was string.

If I pass multi -r, the value will be ['@babel/register', 'esm'], and the type should be array.

Hope this PR can be merged

In my case I need require both ts-node/register and esm

DEPRECATED. Please use webpack-dev-server (he is in support and update mode again). Feel free to create a issue if some features are not implemented in webpack-dev-server.

Why deprecated webpack-serve ?

Thanks for using webpack! We apologize for the inconvenience. In the future, we will avoid such situations.