Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

`sockIntegration: 'whm'` may inject `webpack-hot-middleware/client` twice

オープン
#16 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
52/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
react, typescript
領域
frontend

調査の方向性

Start by tracing the sockIntegration: 'whm' handling and compare it with the prior-art implementation linked in the issue. Reproduce the rspack.config.js scenario with an explicit webpack-hot-middleware/client entry, then verify that the generated bundle contains only one client entry.

索引モデルが issue の本文から書いたものです。

説明

If end-user provide webpack-hot-middleware/client explicitly in the entry. this plugin should skip to inject it.

Scenario
// `rspack.config.js`

export default {
    // ...

    entry: {
	    application: [
		    './src/app.js'
            'webpack-hot-middleware/client?overlay=false&quiet=true',
        ]
    },

    // ...
}

In this case, the output bundle be like below

// ...

function(__webpack_require__) {
var __webpack_exec__ = function(moduleId) { return __webpack_require__(__webpack_require__.s = moduleId) }
__webpack_require__.O(0, ["common",], function() {
        return __webpack_exec__("./node_modules/@rspack/plugin-react-refresh/client/reactRefreshEntry.js"),
             __webpack_exec__("./node_modules/webpack-hot-middleware/client.js"),
             // ^ Injected by this plugin
             __webpack_exec__("./node_modules/@rspack/plugin-react-refresh/client/errorOverlayEntry.js"),
             __webpack_exec__("./src/app.js"),
             __webpack_exec__("./node_modules/webpack-hot-middleware/client.js?overlay=false&quiet=true");
             // ^ Provided by the config
      });
var __webpack_exports__ = __webpack_require__.O();

}
// ...
Prior art

https://github.com/pmmmwh/react-refresh-webpack-plugin/blob/main/lib/index.js#L82-L98

主要言語
TypeScript
スター
20
フォーク
13
平均マージ
2時間 55分
マージ済み PR(30日)
6

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

rstackjs/rspack-plugin-react-refresh のほかの issue

rstackjs/rspack-plugin-react-refresh の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。