From 1a2dd81d27a9fb339a0346d41a5afc381f2ebcf0 Mon Sep 17 00:00:00 2001 From: Michael Mok Date: Mon, 26 Sep 2022 05:33:07 +0200 Subject: [PATCH 1/3] chore: bump core-js --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 5d7c0f88..1caa5e1a 100644 --- a/package.json +++ b/package.json @@ -58,7 +58,7 @@ "dependencies": { "ansi-html-community": "^0.0.8", "common-path-prefix": "^3.0.0", - "core-js-pure": "^3.8.1", + "core-js-pure": "^3.23.3", "error-stack-parser": "^2.0.6", "find-up": "^5.0.0", "html-entities": "^2.1.0", diff --git a/yarn.lock b/yarn.lock index f62f9d2d..0add1d91 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2210,10 +2210,10 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= -core-js-pure@^3.8.1: - version "3.21.1" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.21.1.tgz#8c4d1e78839f5f46208de7230cebfb72bc3bdb51" - integrity sha512-12VZfFIu+wyVbBebyHmRTuEE/tZrB4tJToWcwAMcsp3h4+sHR+fMJWbKpYiCRWlhFBq+KNyO8rIV9rTkeVmznQ== +core-js-pure@^3.23.3: + version "3.25.3" + resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.25.3.tgz#66ac5bfa5754b47fdfd14f3841c5ed21c46db608" + integrity sha512-T/7qvgv70MEvRkZ8p6BasLZmOVYKzOaWNBEHAU8FmveCJkl4nko2quqPQOmy6AJIp5MBanhz9no3A94NoRb0XA== core-util-is@~1.0.0: version "1.0.3" From d07506723a0da36bcebcd1fe705017c5b577a0aa Mon Sep 17 00:00:00 2001 From: Michael Mok Date: Mon, 26 Sep 2022 05:33:27 +0200 Subject: [PATCH 2/3] docs: add CSS HMR --- docs/TROUBLESHOOTING.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/TROUBLESHOOTING.md b/docs/TROUBLESHOOTING.md index 75278f40..0349ffc4 100644 --- a/docs/TROUBLESHOOTING.md +++ b/docs/TROUBLESHOOTING.md @@ -53,6 +53,14 @@ you can fallback to use the legacy dependency resolution algorithm and it should npm install --legacy-peer-deps ``` +## Usage with CSS Files/Imports + +This plugin does not provide HMR for CSS. To achieve that, +you should be using [`style-loader`](https://github.com/webpack-contrib/style-loader) or [`mini-css-extract-plugin`](https://github.com/webpack-contrib/mini-css-extract-plugin). + +Both provides HMR capabilities out of the box for Webpack 5 - +if are still on Webpack 4 and uses `mini-css-extract-plugin`, you might have to [do some setup](https://github.com/webpack-contrib/mini-css-extract-plugin/#hot-module-reloading-hmr). + ## Usage with Indirection (like Workers and JS Templates) If you share the Babel config for files in an indirect code path (e.g. Web Workers, JS Templates with partial pre-render) and all your other source files, From ab33fa88a84c40cbcc3f0bfd2393b388ef19b8e5 Mon Sep 17 00:00:00 2001 From: Michael Mok Date: Mon, 26 Sep 2022 05:33:30 +0200 Subject: [PATCH 3/3] docs: format --- docs/TROUBLESHOOTING.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/TROUBLESHOOTING.md b/docs/TROUBLESHOOTING.md index 0349ffc4..0eba537c 100644 --- a/docs/TROUBLESHOOTING.md +++ b/docs/TROUBLESHOOTING.md @@ -55,7 +55,8 @@ npm install --legacy-peer-deps ## Usage with CSS Files/Imports -This plugin does not provide HMR for CSS. To achieve that, +This plugin does not provide HMR for CSS. +To achieve that, you should be using [`style-loader`](https://github.com/webpack-contrib/style-loader) or [`mini-css-extract-plugin`](https://github.com/webpack-contrib/mini-css-extract-plugin). Both provides HMR capabilities out of the box for Webpack 5 -