@commercetools-frontend/mc-scripts 21.0.0-rc.1 → 21.0.0-rc.2

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.
@@ -96,7 +96,15 @@ module.exports = function createWebpackConfigForDevelopment(options = {}) {
96
96
  // https://github.com/facebook/create-react-app/issues/290
97
97
  // `web` extension prefixes have been added for better support
98
98
  // for React Native Web.
99
- extensions: ['js', 'mjs', 'cjs', 'ts', 'tsx', 'json', 'jsx'].map(ext => `.${ext}`)
99
+ extensions: ['js', 'mjs', 'cjs', 'ts', 'tsx', 'json', 'jsx'].map(ext => `.${ext}`),
100
+ // NOTE: this is meant to be a temporary list of fallback/polyfills for certain
101
+ // nodejs modules. With Webpack <5 these polyfills were included by default in Webpack,
102
+ // however now it's not the case anymore.
103
+ // See also related work in CRA: https://github.com/facebook/create-react-app/pull/11764
104
+ fallback: {
105
+ url: require.resolve('url/'),
106
+ querystring: require.resolve('querystring-es3')
107
+ }
100
108
  },
101
109
  entry: {
102
110
  app: [require.resolve('./application-runtime'), !mergedOptions.toggleFlags.disableCoreJs && require.resolve('core-js/stable'), // When using the experimental `react-refresh` integration,
@@ -138,7 +138,14 @@ module.exports = function createWebpackConfigForProduction(options = {}) {
138
138
  // https://github.com/facebook/create-react-app/issues/290
139
139
  // `web` extension prefixes have been added for better support
140
140
  // for React Native Web.
141
- extensions: ['js', 'mjs', 'cjs', 'ts', 'tsx', 'json', 'jsx'].map(ext => `.${ext}`)
141
+ extensions: ['js', 'mjs', 'cjs', 'ts', 'tsx', 'json', 'jsx'].map(ext => `.${ext}`),
142
+ // NOTE: this is meant to be a temporary list of fallback/polyfills for certain
143
+ // nodejs modules. With Webpack <5 these polyfills were included by default in Webpack,
144
+ // however now it's not the case anymore.
145
+ // See also related work in CRA: https://github.com/facebook/create-react-app/pull/11764
146
+ fallback: {
147
+ querystring: require.resolve('querystring-es3')
148
+ }
142
149
  },
143
150
  // In production, we only want to load the polyfills and the app code.
144
151
  entry: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commercetools-frontend/mc-scripts",
3
- "version": "21.0.0-rc.1",
3
+ "version": "21.0.0-rc.2",
4
4
  "description": "Configuration and scripts for developing a MC application",
5
5
  "bugs": "https://github.com/commercetools/merchant-center-application-kit/issues",
6
6
  "repository": {
@@ -57,7 +57,8 @@
57
57
  "postcss-import": "14.0.2",
58
58
  "postcss-loader": "6.2.1",
59
59
  "postcss-reporter": "7.0.5",
60
- "react-dev-utils": "11.0.4",
60
+ "querystring-es3": "^0.2.1",
61
+ "react-dev-utils": "12.0.0",
61
62
  "react-refresh": "0.11.0",
62
63
  "serve-handler": "6.1.3",
63
64
  "shelljs": "0.8.5",
@@ -65,6 +66,7 @@
65
66
  "svg-url-loader": "7.1.1",
66
67
  "terser-webpack-plugin": "5.3.0",
67
68
  "thread-loader": "3.0.4",
69
+ "url": "^0.11.0",
68
70
  "webpack": "5.66.0",
69
71
  "webpack-bundle-analyzer": "4.5.0",
70
72
  "webpack-dev-server": "4.7.3",