Skip to content
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

Update hot-module-replacement.md #4838

Merged
merged 1 commit into from Apr 11, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/content/guides/hot-module-replacement.md
Expand Up @@ -69,7 +69,7 @@ T> If you took the route of using `webpack-dev-middleware` instead of `webpack-d
};
```

T> You can use the CLI to modify the [webpack-dev-server](https://github.com/webpack/webpack-dev-server) configuration with the following command: `webpack serve --hot=only`.
T> You can use the CLI to modify the [webpack-dev-server](https://github.com/webpack/webpack-dev-server) configuration with the following command: `webpack serve --hot-only`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

webpack serve --hot=only should be now valid with the webpack-cli latest version.

webpack/webpack-cli#2444

Copy link
Member

@chenxsan chenxsan Apr 11, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm it doesn't work with webpack-dev-server 3.11.2.

image

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for confirmation


Now let's update the `index.js` file so that when a change inside `print.js` is detected we tell webpack to accept the updated module.

Expand Down