@jsenv/plugin-react 0.3.4 → 0.3.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/plugin-react",
3
- "version": "0.3.4",
3
+ "version": "0.3.8",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -24,11 +24,11 @@
24
24
  "test": "node --conditions=development ./scripts/test.mjs"
25
25
  },
26
26
  "dependencies": {
27
- "@babel/plugin-transform-react-jsx": "7.18.6",
27
+ "@babel/plugin-transform-react-jsx": "7.19.0",
28
28
  "@babel/plugin-transform-react-jsx-development": "7.18.6",
29
- "@jsenv/ast": "1.2.1",
30
- "@jsenv/plugin-commonjs": "1.0.2",
31
- "@jsenv/sourcemap": "1.0.4",
29
+ "@jsenv/ast": "1.3.0",
30
+ "@jsenv/plugin-commonjs": "1.0.3",
31
+ "@jsenv/sourcemap": "1.0.5",
32
32
  "@jsenv/url-meta": "7.0.0",
33
33
  "react-refresh": "0.14.0"
34
34
  },
@@ -62,7 +62,10 @@ const jsenvPluginJsxAndRefresh = ({
62
62
  associations,
63
63
  })
64
64
  const jsxEnabled = urlMeta.jsx
65
- const refreshEnabled = context.scenarios.dev ? urlMeta.refresh : false
65
+ const refreshEnabled = context.scenarios.dev
66
+ ? urlMeta.refresh &&
67
+ !urlInfo.content.includes("import.meta.hot.decline()")
68
+ : false
66
69
  const babelPlugins = [
67
70
  ...(jsxEnabled
68
71
  ? [