Skip to content

docs: add a webpack-hot-middleware migration guide - #2391

Merged
alexander-akait merged 3 commits into
mainfrom
claude/webpack-dev-middleware-pr-review-dnsl9v
Sep 1, 2026
Merged

docs: add a webpack-hot-middleware migration guide#2391
alexander-akait merged 3 commits into
mainfrom
claude/webpack-dev-middleware-pr-review-dnsl9v

Conversation

@alexander-akait

@alexander-akait alexander-akait commented Sep 1, 2026

Copy link
Copy Markdown
Member

Summary

Now that hot has landed (#2322), webpack-hot-middleware users need a route across. The README's short section could not carry it, so this adds migration-from-webpack-hot-middleware.md — one file with the whole move — and leaves the README with a pointer rather than a second copy.

It covers the prerequisites (the Node.js and webpack floors this package has and that one does not), the server and webpack-configuration changes, every server and client option mapped, the behavior differences that bite (the reload default flipped to true, warnings now shown in the overlay, the payload's dropped module map), the frameworks that used to need third-party bridges, the troubleshooting carried over from that project's README, and a checklist.

What kind of change does this PR introduce?

docs

Did you add tests for your changes?

n/a — documentation only, no source changes. npm run lint is green, which matters here because ESLint parses the fenced JS blocks and Prettier and cspell read the Markdown.

Does this PR introduce a breaking change?

No.

If relevant, what needs to be documented once your changes are merged or what have you already documented?

This is the documentation. One follow-up is worth considering: a note in webpack-hot-middleware's own README pointing at this guide, since that is where its users look — happy to raise it separately.

Use of AI

Written with Claude Code. Every claim was checked against the two code bases rather than recalled: webpack-hot-middleware's middleware.js, client.js and helpers.js for the option defaults, the payload shape and the pathMatch semantics, and this package's merged hot implementation, schema and README for the mapping. Reviewed and verified by a human before submitting.


🤖 Generated with Claude Code

https://claude.ai/code/session_01KUpsHWHZG2FxHzJxRUvVv3


Generated by Claude Code

Summary by CodeRabbit

  • Documentation
    • Added a comprehensive guide for migrating from webpack-hot-middleware to the built-in hot option in webpack-dev-middleware.
    • Documented package and entry-point changes, option and behavior differences, programmatic APIs, troubleshooting, and a migration checklist.
    • Simplified the existing migration section and linked to the dedicated guide.
    • Clarified that compatibility is limited to the endpoint and Server-Sent Events transport.

One file, migration-from-webpack-hot-middleware.md: prerequisites (the
node.js and webpack floors this package has and that one does not), the
server and webpack-configuration changes, every server and client option
mapped, the behavior differences that bite (the `reload` default, warnings
in the overlay, the dropped module map), the framework recipes that used to
need third-party bridges, the troubleshooting carried over from that
project's README, and a checklist. README keeps a pointer instead of a
second copy.
@changeset-bot

changeset-bot Bot commented Sep 1, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: ff5a85e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@codecov

codecov Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.19%. Comparing base (dbbece3) to head (ff5a85e).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2391   +/-   ##
=======================================
  Coverage   94.19%   94.19%           
=======================================
  Files           4        4           
  Lines        1240     1240           
  Branches      380      380           
=======================================
  Hits         1168     1168           
  Misses         64       64           
  Partials        8        8           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@coderabbitai

coderabbitai Bot commented Sep 1, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: c6edcd38-0e1d-4c54-b4d1-b82f2c477f48

📥 Commits

Reviewing files that changed from the base of the PR and between f1b74c5 and ff5a85e.

📒 Files selected for processing (1)
  • migration-from-webpack-hot-middleware.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • migration-from-webpack-hot-middleware.md

Included review availability: Your plan provides up to 8 included reviews per hour; 5 remain after this review.


Walkthrough

The README now links to a dedicated migration guide. The guide documents prerequisites, package changes, middleware replacement, client entry changes, framework wrappers, compiler configuration, option mappings, behavior differences, programmatic APIs, troubleshooting, and a migration checklist. It also defines the compatibility boundary for the built-in hot option.

Merge Risk: ⚪ Minimal · up to ff5a8

This documentation-only change adds a migration guide and updates the README pointer; no actionable merge-blocking risk remains after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding documentation for migrating from webpack-hot-middleware.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/webpack-dev-middleware-pr-review-dnsl9v

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 2


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: ce6ca997-7ab3-4cc0-a9b1-fac20921472f

📥 Commits

Reviewing files that changed from the base of the PR and between dbbece3 and 047496d.

📒 Files selected for processing (2)
  • README.md
  • migration-from-webpack-hot-middleware.md

Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review.

Comment thread migration-from-webpack-hot-middleware.md Outdated
Comment thread README.md Outdated
Removing webpack-hot-middleware does not upgrade the package that replaces
it, so the guide now says to install it and shows the validation error an
older version answers `hot` with (taken from schema-utils, not written from
memory). The opening claimed the wire format was unchanged, which oversold
it: the endpoint and its transport are, the payloads, option names and a few
defaults are not, and the two sections that cover them are linked from
there.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 3f7a16de-0a7a-4880-85dd-f5e7281afffd

📥 Commits

Reviewing files that changed from the base of the PR and between 047496d and f1b74c5.

📒 Files selected for processing (2)
  • README.md
  • migration-from-webpack-hot-middleware.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • README.md

Included review availability: Your plan provides up to 8 included reviews per hour; 6 remain after this review.

Comment thread migration-from-webpack-hot-middleware.md Outdated
Every other fence in the guide names its language; this one did not, which
markdownlint reports as MD040.
@alexander-akait
alexander-akait merged commit 08ce43d into main Sep 1, 2026
20 checks passed
@alexander-akait
alexander-akait deleted the claude/webpack-dev-middleware-pr-review-dnsl9v branch September 1, 2026 19:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant