JSPM

  • Created
  • Published
  • Downloads 19
  • Score
    100M100P100Q57310F
  • License MIT

Start a Webpack Dev Server to run WebdriverIO against

Package Exports

  • wdio-webpack-dev-server-service

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (wdio-webpack-dev-server-service) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

WDIO Webpack Dev Server Service

This service starts Webpack Dev Server for you to run WebdriverIO against.

Installation

npm install wdio-webpack-dev-server-service --save-dev

Configuration

This assumes you have:

Note: If you need support for webpack-dev-server (which is in maintenance mode) and Webpack 2 or 3, use webpack-dev-server-service@1.2.0.

Add the Webpack Dev Server service to your WebdriverIO services list:

// wdio.conf.js
export.config = {
  // ...
  services: ['webpack-dev-server'],
  // ...
};

Options are set directly on your WebdriverIO config as well, e.g.

// wdio.conf.js
export.config = {
  // ...
  webpackConfig: require('webpack.dev.config.js'),
  webpackPort: 8080,
  // ...
};

Options

webpackConfig

Type: String | Function | Object

Default: webpack.config.js

Either the absolute path to your Webpack configuration, or (a function generating) your actual Webpack configuration.

webpackPort

Type: Number

Default: 8080

The port the Dev Server should be run on. You'll want to set this same port in the baseUrl option of your WebdriverIO configuration.