@infomaximum/package-cli 2.24.0-0 → 2.24.0-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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ## [2.24.0-2](https://github.com/Infomaximum/package-cli/compare/v2.24.0-1...v2.24.0-2) (2025-06-20)
6
+
7
+ ## [2.24.0-1](https://github.com/Infomaximum/package-cli/compare/v2.24.0-0...v2.24.0-1) (2025-06-20)
8
+
9
+
10
+ ### Bug Fixes
11
+
12
+ * убрано копирование ресурсов при сборке скрипта ([9084cab](https://github.com/Infomaximum/package-cli/commit/9084cab37462fadf4ad15169ea7d701a18698199))
13
+
5
14
  ## [2.24.0-0](https://github.com/Infomaximum/package-cli/compare/v2.23.1...v2.24.0-0) (2025-06-20)
6
15
 
7
16
 
@@ -8,6 +8,6 @@ export type WidgetRCConfig = {
8
8
  buildDir: string;
9
9
  port: number;
10
10
  host: string;
11
- externals?: Partial<SystemWidgetExternals>;
11
+ externalsLib?: Partial<SystemWidgetExternals>;
12
12
  };
13
13
  export declare const getConfigFromFile: () => WidgetRCConfig | undefined;
@@ -1,4 +1,4 @@
1
1
  import { type Configuration } from "webpack";
2
2
  import type { Mode } from "../../../paths.js";
3
3
  import type { WidgetPaths } from "../../widgetPaths.js";
4
- export declare const getCommonWidgetConfig: (mode: Mode, PATHS: WidgetPaths) => Configuration;
4
+ export declare const getCommonWidgetConfig: (mode: Mode, PATHS: WidgetPaths, isCopyResources?: boolean) => Configuration;
@@ -9,7 +9,7 @@ import { WIDGET_OUTPUT_FILE_NAME, WIDGET_OUTPUT_FULL_FILE_NAME, } from "../../co
9
9
  const { ProgressPlugin } = webpack;
10
10
  const isProduction = (mode) => mode === "production";
11
11
  const isDevelopment = (mode) => mode === "development";
12
- export const getCommonWidgetConfig = (mode, PATHS) => {
12
+ export const getCommonWidgetConfig = (mode, PATHS, isCopyResources = true) => {
13
13
  const manifestEntry = systemRequire(PATHS.widgetManifestJsonPath).entry;
14
14
  const filename = isProduction(mode)
15
15
  ? `${WIDGET_OUTPUT_FILE_NAME}.[contenthash].js`
@@ -34,7 +34,8 @@ export const getCommonWidgetConfig = (mode, PATHS) => {
34
34
  },
35
35
  },
36
36
  }),
37
- PATHS.widgetResourcesPath &&
37
+ isCopyResources &&
38
+ PATHS.widgetResourcesPath &&
38
39
  PATHS.widgetResourcesDirName &&
39
40
  new CopyWebpackPlugin({
40
41
  patterns: [
@@ -115,12 +116,9 @@ export const getCommonWidgetConfig = (mode, PATHS) => {
115
116
  resourceQuery: /url/,
116
117
  parser: {
117
118
  dataUrlCondition: {
118
- maxSize: 64 * 1024,
119
+ maxSize: Infinity,
119
120
  },
120
121
  },
121
- generator: {
122
- filename: "build/static/[hash][ext][query]",
123
- },
124
122
  },
125
123
  {
126
124
  type: "asset/source",
@@ -19,9 +19,9 @@ export const runBuildScript = (args, config) => __awaiter(void 0, void 0, void 0
19
19
  },
20
20
  };
21
21
  const configSections = [
22
- getCommonWidgetConfig(mode, WIDGET_PATHS),
22
+ getCommonWidgetConfig(mode, WIDGET_PATHS, false),
23
23
  {
24
- externals: (_a = config === null || config === void 0 ? void 0 : config.externals) !== null && _a !== void 0 ? _a : {},
24
+ externals: (_a = config === null || config === void 0 ? void 0 : config.externalsLib) !== null && _a !== void 0 ? _a : {},
25
25
  externalsType: "window",
26
26
  },
27
27
  sections,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infomaximum/package-cli",
3
- "version": "2.24.0-0",
3
+ "version": "2.24.0-2",
4
4
  "exports": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "type": "module",
@@ -40,7 +40,7 @@
40
40
  "type": "string",
41
41
  "description": "хост по которому будет доступен сервер разработки"
42
42
  },
43
- "externals": {
43
+ "externalsLib": {
44
44
  "type": "object",
45
45
  "additionalProperties": true,
46
46
  "description": "исключает указанные зависимости из сборки, предполагая их наличие в окружении. Используется для уменьшения размера бандла. Актуально только при сборке скрипта. (https://webpack.js.org/configuration/externals/)"