Skip to content

Commit 244f74d

Browse files
John Richard Chipps-HardingEugeneHlushko
John Richard Chipps-Harding
andcommitted
docs(DevServer): expand on devServer.openPage usage (#3306)
* docs(dev-server): expand on `devServer.openPage` usage * fix: linting * Update src/content/configuration/dev-server.md Co-Authored-By: Eugene Hlushko <[email protected]>
1 parent a79228b commit 244f74d

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

src/content/configuration/dev-server.md

+21-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ contributors:
1313
- Loonride
1414
- dmohns
1515
- EslamHiko
16+
- digitaljohn
1617
---
1718

1819
[webpack-dev-server](https://github.com/webpack/webpack-dev-server) can be used to quickly develop an application. See the [development guide](/guides/development/) to get started.
@@ -804,7 +805,7 @@ T> The browser application name is platform dependent. Don't hard code it in reu
804805

805806
## `devServer.openPage`
806807

807-
`string`
808+
`string` `[string]`
808809

809810
Specify a page to navigate to when opening the browser.
810811

@@ -825,6 +826,25 @@ Usage via the CLI
825826
webpack-dev-server --open-page "/different/page"
826827
```
827828

829+
If you wish to specify multiple pages to open in the browser.
830+
831+
__webpack.config.js__
832+
833+
```javascript
834+
module.exports = {
835+
//...
836+
devServer: {
837+
openPage: ['/different/page1', '/different/page2']
838+
}
839+
};
840+
```
841+
842+
Usage via the CLI
843+
844+
```bash
845+
webpack-dev-server --open-page "/different/page1,/different/page2"
846+
```
847+
828848

829849
## `devServer.overlay`
830850

0 commit comments

Comments
 (0)