Browse Source

feat(build) drop export-default-from plugin

The proposal never passed stage 1 and was last updated 4 years ago,
which signals it won't make it into the language: https://github.com/tc39/proposal-export-default-from

The alternative is just a couple of characters longer.
factor2
Saúl Ibarra Corretgé 8 months ago
parent
commit
aedb43ec5b
4 changed files with 1 additions and 9 deletions
  1. 1
    1
      modules/API/index.js
  2. 0
    1
      package-lock.json
  3. 0
    1
      package.json
  4. 0
    6
      webpack.config.js

+ 1
- 1
modules/API/index.js View File

@@ -1,2 +1,2 @@
1
-export default from './API';
1
+export { default } from './API';
2 2
 export * from './constants';

+ 0
- 1
package-lock.json View File

@@ -125,7 +125,6 @@
125 125
       "devDependencies": {
126 126
         "@babel/core": "7.25.9",
127 127
         "@babel/eslint-parser": "7.25.9",
128
-        "@babel/plugin-proposal-export-default-from": "7.25.9",
129 128
         "@babel/plugin-transform-private-methods": "7.25.9",
130 129
         "@babel/preset-env": "7.25.9",
131 130
         "@babel/preset-react": "7.25.9",

+ 0
- 1
package.json View File

@@ -131,7 +131,6 @@
131 131
   "devDependencies": {
132 132
     "@babel/core": "7.25.9",
133 133
     "@babel/eslint-parser": "7.25.9",
134
-    "@babel/plugin-proposal-export-default-from": "7.25.9",
135 134
     "@babel/plugin-transform-private-methods": "7.25.9",
136 135
     "@babel/preset-env": "7.25.9",
137 136
     "@babel/preset-react": "7.25.9",

+ 0
- 6
webpack.config.js View File

@@ -109,12 +109,6 @@ function getConfig(options = {}) {
109 109
                     // Avoid loading babel.config.js, since we only use it for React Native.
110 110
                     configFile: false,
111 111
 
112
-                    // XXX The require.resolve below solves failures to locate the
113
-                    // presets when lib-jitsi-meet, for example, is npm linked in
114
-                    // jitsi-meet.
115
-                    plugins: [
116
-                        require.resolve('@babel/plugin-proposal-export-default-from')
117
-                    ],
118 112
                     presets: [
119 113
                         [
120 114
                             require.resolve('@babel/preset-env'),

Loading…
Cancel
Save