Skip to content

Add @rspack/core to the peer dependencies of html-webpack-plugin and react-refresh-webpack-plugin #4537

@chenjiahan

Description

@chenjiahan

What problem does this feature solve?

Can we add @rspack/core to the peer dependencies of html-webpack-plugin and react-refresh-webpack-plugin (and more popular webpack plugins), then make webpack as an optional dependency?

The benifits:

  • Users do not need to install webpack as a dependency.
  • No peer dependency missing warning.

What does the proposed API of configuration look like?

{
  "peerDependencies": {
    "@rspack/core": ">=0.3.0",
    "webpack": ">=4.43.0 <6.0.0",
  },
  "peerDependenciesMeta": {
    "webpack": {
      "optional": true
    },
   "@rspack/core": {
      "optional": true
    }
  },
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    featNew feature or requestrsbuildrsbuild relatedteamThe issue/pr is created by the member of Rspack.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions