@jsenv/plugin-react 1.1.6 → 1.1.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": "1.1.6",
3
+ "version": "1.1.8",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -26,8 +26,8 @@
26
26
  "dependencies": {
27
27
  "@babel/plugin-transform-react-jsx": "7.19.0",
28
28
  "@babel/plugin-transform-react-jsx-development": "7.18.6",
29
- "@jsenv/ast": "1.4.4",
30
- "@jsenv/plugin-commonjs": "1.1.1",
29
+ "@jsenv/ast": "1.4.5",
30
+ "@jsenv/plugin-commonjs": "1.1.3",
31
31
  "@jsenv/sourcemap": "1.0.7",
32
32
  "@jsenv/url-meta": "7.0.0",
33
33
  "react-refresh": "0.14.0"
@@ -73,7 +73,7 @@ const jsenvPluginJsxAndRefresh = ({
73
73
  associations,
74
74
  })
75
75
  const jsxEnabled = urlMeta.jsxTranspilation
76
- const refreshEnabled = context.scenarios.dev
76
+ const refreshEnabled = context.dev
77
77
  ? urlMeta.refreshInstrumentation &&
78
78
  !urlInfo.content.includes("import.meta.hot.decline()")
79
79
  : false
@@ -81,7 +81,7 @@ const jsenvPluginJsxAndRefresh = ({
81
81
  ...(jsxEnabled
82
82
  ? [
83
83
  [
84
- context.scenarios.dev
84
+ context.dev
85
85
  ? "@babel/plugin-transform-react-jsx-development"
86
86
  : "@babel/plugin-transform-react-jsx",
87
87
  {
@@ -118,7 +118,7 @@ const jsenvPluginJsxAndRefresh = ({
118
118
  while (index > -1) {
119
119
  const specifier = importSpecifier.slice(1, -1)
120
120
  const [injectedReference] = context.referenceUtils.inject({
121
- type: "js_import_export",
121
+ type: "js_import",
122
122
  expectedType: "js_module",
123
123
  specifier,
124
124
  })
@@ -137,7 +137,7 @@ const jsenvPluginJsxAndRefresh = ({
137
137
  if (hasReg || hasSig) {
138
138
  const [reactRefreshClientReference] = context.referenceUtils.inject(
139
139
  {
140
- type: "js_import_export",
140
+ type: "js_import",
141
141
  expectedType: "js_module",
142
142
  specifier: "@jsenv/plugin-react/src/client/react_refresh.js",
143
143
  },