-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(devserver): add documentation for liveReload option #3051
Changes from 4 commits
4d3b347
8dfc580
b66ba9a
ff2fcd5
2d1bdd7
7fc1f71
8b5b8b2
4446db1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -696,6 +696,29 @@ T> [`watchOptions`](#devserver-watchoptions-) will have no effect when used with | |||||
|
||||||
T> If you use the CLI, make sure __inline mode__ is disabled. | ||||||
|
||||||
## `devServer.liveReload` | ||||||
|
||||||
`boolean: true` | ||||||
|
||||||
When `devServer.liveReload` is enabled, the dev-server will reload/refresh the page when file changes if [`devServer.hot`](#devserverhot) option is disabled or [`devServer.watchContentBase`](#devserverwatchcontentbase) is enabled. | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
|
||||||
__webpack.config.js__ | ||||||
|
||||||
```javascript | ||||||
module.exports = { | ||||||
//... | ||||||
devServer: { | ||||||
liveReload: true | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
} | ||||||
}; | ||||||
``` | ||||||
|
||||||
Usage via the CLI | ||||||
|
||||||
```bash | ||||||
webpack-dev-server --live-reload | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Isn't this default? Why we need to pass it |
||||||
``` | ||||||
|
||||||
|
||||||
## `devServer.mimeTypes` 🔑 | ||||||
|
||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.