ics-builder 4.4.9 → 4.4.11

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": "ics-builder",
3
- "version": "4.4.9",
3
+ "version": "4.4.11",
4
4
  "description": "",
5
5
  "main": "./src/index.js",
6
6
  "preferGlobal": true,
@@ -247,6 +247,9 @@ var WebpackUiBuilder = /** @class */ (function (_super) {
247
247
  resolveAlias["react"] = path.resolve(basePath, "ui", "./node_modules/react");
248
248
  resolveAlias["react-dom"] = path.resolve(basePath, "ui", "./node_modules/react-dom");
249
249
  }
250
+ // Библиотеки с современным синтаксисом, которые нужно транспилировать для webpack 4
251
+ var packagesToTranspile = ["ics-ui-kit", "zustand-computed"];
252
+ var transpileRegex = new RegExp(packagesToTranspile.join("|"));
250
253
  return {
251
254
  context: path.join(this.config.paths.source, "mdt/ui"),
252
255
  mode: this.isProd() ? "production" : "development",
@@ -282,8 +285,8 @@ var WebpackUiBuilder = /** @class */ (function (_super) {
282
285
  // Обработка современного JS из библиотеки ics-ui-kit для совместимости со старыми браузерами (IE 10+)
283
286
  // Babel транспилирует ES2020+ синтаксис (nullish coalescing ??, optional chaining ?.) в ES5
284
287
  {
285
- test: /\.js$/,
286
- include: /ics-ui-kit/,
288
+ test: /\.m?js$/,
289
+ include: transpileRegex,
287
290
  use: {
288
291
  loader: require.resolve("babel-loader"),
289
292
  options: {