Skip to content

chore: rename from webpack-dev-middleware to @rspack/dev-middleware#7

Merged
chenjiahan merged 1 commit intomainfrom
rename_repo_0314
Mar 14, 2026
Merged

chore: rename from webpack-dev-middleware to @rspack/dev-middleware#7
chenjiahan merged 1 commit intomainfrom
rename_repo_0314

Conversation

@chenjiahan
Copy link
Copy Markdown
Member

Update package name, documentation, and references to reflect the transition from webpack-dev-middleware to @rspack/dev-middleware. This includes updating package.json, README.md, and CONTRIBUTING.md files to reference the new package name and repository.

Copilot AI review requested due to automatic review settings March 14, 2026 03:30
@gemini-code-assist
Copy link
Copy Markdown

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request rebrands the development middleware package from webpack-dev-middleware to @rspack/dev-middleware. The primary goal is to reflect its transition and compatibility with the Rspack build tool, ensuring that all references, documentation, and package metadata are consistent with the new naming convention. This change clarifies the package's purpose and integration within the Rspack ecosystem.

Highlights

  • Package Renaming: The package has been renamed from "webpack-dev-middleware" to "@rspack/dev-middleware" to align with the Rspack ecosystem.
  • Documentation Updates: All relevant documentation files, including README.md and CONTRIBUTING.md, have been updated to reflect the new package name, installation instructions, and Rspack compatibility.
  • Metadata Alignment: Package metadata in package.json and package-lock.json has been updated to use the new package name, description, keywords, and repository links.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • CONTRIBUTING.md
    • Updated the main heading to reflect the new package name.
    • Modified the devDependencies entry to reference the new @rspack/dev-middleware package and its repository.
  • README.md
    • Updated the main title of the README to @rspack/dev-middleware.
    • Adjusted the description to mention Rspack compatibility.
    • Changed installation commands from npm install webpack-dev-middleware to npm install @rspack/dev-middleware.
    • Updated all require and direct calls to webpack-dev-middleware to @rspack/dev-middleware in code examples.
    • Revised comments for middleware options to be generic or specific to @rspack/dev-middleware.
    • Updated API method references to use @rspack/dev-middleware.
    • Modified various badge URLs (npm, node, tests, cover, size) and repository links to point to the new @rspack/dev-middleware and rstackjs organization.
  • package-lock.json
    • Updated the package name in the lock file from webpack-dev-middleware to @rspack/dev-middleware.
  • package.json
    • Renamed the package from webpack-dev-middleware to @rspack/dev-middleware.
    • Updated the package description to mention Rspack.
    • Added rspack to the list of keywords.
    • Changed the homepage, bugs, and repository URLs to reflect the rstackjs organization and the new package name.
Activity
  • No human activity has been recorded on this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@chenjiahan chenjiahan merged commit b209be4 into main Mar 14, 2026
14 of 17 checks passed
@chenjiahan chenjiahan deleted the rename_repo_0314 branch March 14, 2026 03:30
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the package name and documentation from webpack-dev-middleware to @rspack/dev-middleware. The changes are mostly in documentation and configuration files like package.json.

I've found a critical typo in the new repository/organization name (rstackjs instead of rspackjs) across multiple files, which will lead to broken links and incorrect repository references. I've also pointed out some minor inconsistencies in code comments within the README.md for better clarity. Please address these points.

{
"devDependencies": {
"webpack-dev-middleware": "webpack/webpack-dev-middleware#{id}/head"
"@rspack/dev-middleware": "rstackjs/rspack-dev-middleware#{id}/head"
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

critical

There seems to be a typo in the organization name. It should be rspackjs instead of rstackjs to match the @rspack/dev-middleware package's organization.

Suggested change
"@rspack/dev-middleware": "rstackjs/rspack-dev-middleware#{id}/head"
"@rspack/dev-middleware": "rspackjs/rspack-dev-middleware#{id}/head"

Comment on lines +777 to +788
[tests]: https://github.com/rstackjs/rspack-dev-middleware/actions/workflows/test.yml/badge.svg
[tests-url]: https://github.com/rstackjs/rspack-dev-middleware/actions
[cover]: https://codecov.io/gh/rstackjs/rspack-dev-middleware/branch/main/graph/badge.svg
[cover-url]: https://codecov.io/gh/rstackjs/rspack-dev-middleware
[discussion]: https://img.shields.io/github/discussions/webpack/webpack
[discussion-url]: https://github.com/webpack/webpack/discussions
[size]: https://packagephobia.com/badge?p=webpack-dev-middleware
[size-url]: https://packagephobia.com/result?p=webpack-dev-middleware
[docs-url]: https://webpack.js.org/guides/development/#using-webpack-dev-middleware
[size]: https://packagephobia.com/badge?p=%40rspack%2Fdev-middleware
[size-url]: https://packagephobia.com/result?p=%40rspack%2Fdev-middleware
[docs-url]: https://github.com/rstackjs/rspack-dev-middleware#readme
[hash-url]: https://twitter.com/search?q=webpack
[middleware-url]: https://github.com/webpack/webpack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/webpack-dev-middleware
[middleware-url]: https://github.com/rstackjs/rspack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/rspack-dev-middleware
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

critical

There seems to be a typo in the organization name in several URLs. It should be rspackjs instead of rstackjs.

Suggested change
[tests]: https://github.com/rstackjs/rspack-dev-middleware/actions/workflows/test.yml/badge.svg
[tests-url]: https://github.com/rstackjs/rspack-dev-middleware/actions
[cover]: https://codecov.io/gh/rstackjs/rspack-dev-middleware/branch/main/graph/badge.svg
[cover-url]: https://codecov.io/gh/rstackjs/rspack-dev-middleware
[discussion]: https://img.shields.io/github/discussions/webpack/webpack
[discussion-url]: https://github.com/webpack/webpack/discussions
[size]: https://packagephobia.com/badge?p=webpack-dev-middleware
[size-url]: https://packagephobia.com/result?p=webpack-dev-middleware
[docs-url]: https://webpack.js.org/guides/development/#using-webpack-dev-middleware
[size]: https://packagephobia.com/badge?p=%40rspack%2Fdev-middleware
[size-url]: https://packagephobia.com/result?p=%40rspack%2Fdev-middleware
[docs-url]: https://github.com/rstackjs/rspack-dev-middleware#readme
[hash-url]: https://twitter.com/search?q=webpack
[middleware-url]: https://github.com/webpack/webpack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/webpack-dev-middleware
[middleware-url]: https://github.com/rstackjs/rspack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/rspack-dev-middleware
[tests]: https://github.com/rspackjs/rspack-dev-middleware/actions/workflows/test.yml/badge.svg
[tests-url]: https://github.com/rspackjs/rspack-dev-middleware/actions
[cover]: https://codecov.io/gh/rspackjs/rspack-dev-middleware/branch/main/graph/badge.svg
[cover-url]: https://codecov.io/gh/rspackjs/rspack-dev-middleware
[discussion]: https://img.shields.io/github/discussions/webpack/webpack
[discussion-url]: https://github.com/webpack/webpack/discussions
[size]: https://packagephobia.com/badge?p=%40rspack%2Fdev-middleware
[size-url]: https://packagephobia.com/result?p=%40rspack%2Fdev-middleware
[docs-url]: https://github.com/rspackjs/rspack-dev-middleware#readme
[hash-url]: https://twitter.com/search?q=webpack
[middleware-url]: https://github.com/rspackjs/rspack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/rspack-dev-middleware

Comment on lines +11 to +13
"homepage": "https://github.com/rstackjs/rspack-dev-middleware",
"bugs": "https://github.com/rstackjs/rspack-dev-middleware/issues",
"repository": "rstackjs/rspack-dev-middleware",
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

critical

There seems to be a typo in the organization name in the homepage, bugs, and repository URLs. It should be rspackjs instead of rstackjs.

Suggested change
"homepage": "https://github.com/rstackjs/rspack-dev-middleware",
"bugs": "https://github.com/rstackjs/rspack-dev-middleware/issues",
"repository": "rstackjs/rspack-dev-middleware",
"homepage": "https://github.com/rspackjs/rspack-dev-middleware",
"bugs": "https://github.com/rspackjs/rspack-dev-middleware/issues",
"repository": "rspackjs/rspack-dev-middleware",

app.use(
middleware(compiler, {
// webpack-dev-middleware options
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment, similar to another part of this file.

Suggested change
// options
// @rspack/dev-middleware options

const compiler = webpack(webpackConfig);
const devMiddlewareOptions = {
/** Your webpack-dev-middleware-options */
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment.

Suggested change
// options
// @rspack/dev-middleware options

const compiler = webpack(webpackConfig);
const devMiddlewareOptions = {
/** Your webpack-dev-middleware-options */
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment.

Suggested change
// options
// @rspack/dev-middleware options

const compiler = webpack(webpackConfig);
const devMiddlewareOptions = {
/** Your webpack-dev-middleware-options */
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment.

Suggested change
// options
// @rspack/dev-middleware options


await server.register({
plugin: devMiddleware.hapiPlugin(),
plugin: devMiddleware.hapiWrapper(),
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The method hapiPlugin has been renamed to hapiWrapper. This seems to be a functional change that should be noted. The name hapiWrapper is more descriptive of its purpose.

const compiler = webpack(webpackConfig);
const devMiddlewareOptions = {
/** Your webpack-dev-middleware-options */
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment.

Suggested change
// options
// @rspack/dev-middleware options

const compiler = webpack(webpackConfig);
const devMiddlewareOptions = {
/** Your webpack-dev-middleware-options */
// options
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency and clarity, it would be better to use // @rspack/dev-middleware options as the placeholder comment.

Suggested change
// options
// @rspack/dev-middleware options

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Renames the package and updates documentation/repository metadata to reflect the transition from webpack-dev-middleware to @rspack/dev-middleware.

Changes:

  • Renamed the npm package to @rspack/dev-middleware and updated repository/homepage/bugs metadata.
  • Updated README installation/usage examples and badge links to the new package/repo.
  • Updated contributing docs to reference the new package and repo for PR testing.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 7 comments.

File Description
package.json Updates package name/description and repo metadata to rstackjs/rspack-dev-middleware.
package-lock.json Updates lockfile root package name to match the new scoped name.
README.md Renames the project in docs, updates install/require examples, and updates various repo/badge links.
CONTRIBUTING.md Renames the project heading and updates the example dependency to the new repo/package.
Comments suppressed due to low confidence (1)

package.json:17

  • homepage/bugs/repository were updated to the new repo, but funding.url still points to the webpack OpenCollective. If this package has moved to the Rspack org, update (or remove) the funding link so it doesn't direct users to the wrong project.
  "repository": "rstackjs/rspack-dev-middleware",
  "funding": {
    "type": "opencollective",
    "url": "https://opencollective.com/webpack"
  },

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 781 to +784
[discussion]: https://img.shields.io/github/discussions/webpack/webpack
[discussion-url]: https://github.com/webpack/webpack/discussions
[size]: https://packagephobia.com/badge?p=webpack-dev-middleware
[size-url]: https://packagephobia.com/result?p=webpack-dev-middleware
[docs-url]: https://webpack.js.org/guides/development/#using-webpack-dev-middleware
[size]: https://packagephobia.com/badge?p=%40rspack%2Fdev-middleware
[size-url]: https://packagephobia.com/result?p=%40rspack%2Fdev-middleware
Comment on lines +1 to 4
# Contributing in @rspack/dev-middleware

We'd always love contributions to further improve the webpack / webpack-contrib ecosystem!
Here are the guidelines we'd like you to follow:
{
"devDependencies": {
"webpack-dev-middleware": "webpack/webpack-dev-middleware#{id}/head"
"@rspack/dev-middleware": "rstackjs/rspack-dev-middleware#{id}/head"
Comment on lines +787 to 790
[middleware-url]: https://github.com/rstackjs/rspack-dev-middleware
[stack-url]: https://stackoverflow.com/questions/tagged/rspack-dev-middleware
[chat-url]: https://github.com/webpack/webpack/discussions
[wjo-url]: https://github.com/webpack/webpack.js.org
Comment on lines 12 to +16
[![size][size]][size-url]

# webpack-dev-middleware
# @rspack/dev-middleware

An express-style development middleware for use with [Rspack](https://rspack.rs) and webpack-compatible compilers. It serves the files emitted by the compiler from memory.
## API

`webpack-dev-middleware` also provides convenience methods that can be use to
`@rspack/dev-middleware` also provides convenience methods that can be use to
Comment on lines +777 to +778
[tests]: https://github.com/rstackjs/rspack-dev-middleware/actions/workflows/test.yml/badge.svg
[tests-url]: https://github.com/rstackjs/rspack-dev-middleware/actions
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.

2 participants