@tramvai/cli 7.4.2 → 7.4.4

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.
Files changed (96) hide show
  1. package/__migrations__/d2026-01-28b-tramvai-config-remove-transpileOnlyModernLibs.js +31 -0
  2. package/lib/api/analyze/index.d.ts +1 -1
  3. package/lib/api/analyze/index.d.ts.map +1 -1
  4. package/lib/api/start/index.d.ts +1 -1
  5. package/lib/api/start/index.d.ts.map +1 -1
  6. package/lib/builder/webpack/analyzePlugins/bundle.d.ts +1 -1
  7. package/lib/builder/webpack/analyzePlugins/bundle.js +1 -1
  8. package/lib/builder/webpack/analyzePlugins/bundle.js.map +1 -1
  9. package/lib/builder/webpack/analyzePlugins/rsdoctor.d.ts +0 -4
  10. package/lib/builder/webpack/analyzePlugins/rsdoctor.d.ts.map +1 -1
  11. package/lib/builder/webpack/analyzePlugins/rsdoctor.js +0 -1
  12. package/lib/builder/webpack/analyzePlugins/rsdoctor.js.map +1 -1
  13. package/lib/builder/webpack/analyzePlugins/statoscope.d.ts +3 -7
  14. package/lib/builder/webpack/analyzePlugins/statoscope.d.ts.map +1 -1
  15. package/lib/builder/webpack/analyzePlugins/statoscope.js +6 -26
  16. package/lib/builder/webpack/analyzePlugins/statoscope.js.map +1 -1
  17. package/lib/builder/webpack/analyzePlugins/stats.d.ts +12 -0
  18. package/lib/builder/webpack/analyzePlugins/stats.d.ts.map +1 -0
  19. package/lib/builder/webpack/analyzePlugins/stats.js +40 -0
  20. package/lib/builder/webpack/analyzePlugins/stats.js.map +1 -0
  21. package/lib/builder/webpack/analyzePlugins/whyBundled.d.ts +1 -1
  22. package/lib/builder/webpack/analyzePlugins/whyBundled.d.ts.map +1 -1
  23. package/lib/builder/webpack/analyzePlugins/whyBundled.js +1 -1
  24. package/lib/builder/webpack/analyzePlugins/whyBundled.js.map +1 -1
  25. package/lib/builder/webpack/providers/build/server.d.ts.map +1 -1
  26. package/lib/builder/webpack/providers/build/server.js +5 -2
  27. package/lib/builder/webpack/providers/build/server.js.map +1 -1
  28. package/lib/builder/webpack/providers/shared.d.ts.map +1 -1
  29. package/lib/builder/webpack/providers/shared.js +2 -0
  30. package/lib/builder/webpack/providers/shared.js.map +1 -1
  31. package/lib/builder/webpack/providers/start/shared.d.ts.map +1 -1
  32. package/lib/builder/webpack/providers/start/shared.js +10 -4
  33. package/lib/builder/webpack/providers/start/shared.js.map +1 -1
  34. package/lib/builder/webpack/tokens.d.ts +0 -2
  35. package/lib/builder/webpack/tokens.d.ts.map +1 -1
  36. package/lib/builder/webpack/types.d.ts +2 -1
  37. package/lib/builder/webpack/types.d.ts.map +1 -1
  38. package/lib/builder/webpack/types.js +3 -1
  39. package/lib/builder/webpack/types.js.map +1 -1
  40. package/lib/commands/analyze/command.js +1 -1
  41. package/lib/commands/analyze/command.js.map +1 -1
  42. package/lib/commands/build/command.d.ts.map +1 -1
  43. package/lib/commands/build/command.js +6 -1
  44. package/lib/commands/build/command.js.map +1 -1
  45. package/lib/commands/start/command.js +1 -1
  46. package/lib/commands/start/command.js.map +1 -1
  47. package/lib/config/configManager.d.ts +2 -1
  48. package/lib/config/configManager.d.ts.map +1 -1
  49. package/lib/config/configManager.js +1 -0
  50. package/lib/config/configManager.js.map +1 -1
  51. package/lib/di/tokens/config.d.ts +0 -1
  52. package/lib/di/tokens/config.d.ts.map +1 -1
  53. package/lib/library/webpack/blocks/js.d.ts.map +1 -1
  54. package/lib/library/webpack/blocks/js.js +1 -2
  55. package/lib/library/webpack/blocks/js.js.map +1 -1
  56. package/lib/library/webpack/blocks/optimize.d.ts.map +1 -1
  57. package/lib/library/webpack/blocks/optimize.js +7 -1
  58. package/lib/library/webpack/blocks/optimize.js.map +1 -1
  59. package/lib/library/webpack/child-app/common.d.ts.map +1 -1
  60. package/lib/library/webpack/child-app/common.js +2 -10
  61. package/lib/library/webpack/child-app/common.js.map +1 -1
  62. package/lib/library/webpack/common/main.js +1 -1
  63. package/lib/library/webpack/common/main.js.map +1 -1
  64. package/lib/schema/autogeneratedSchema.json +15 -30
  65. package/lib/typings/configEntry/cli.d.ts +0 -5
  66. package/lib/typings/configEntry/cli.d.ts.map +1 -1
  67. package/package.json +8 -7
  68. package/schema.json +15 -30
  69. package/src/api/analyze/index.ts +1 -1
  70. package/src/api/build/__integration__/build.test.ts +8 -8
  71. package/src/api/start/index.ts +1 -1
  72. package/src/builder/webpack/analyzePlugins/bundle.ts +1 -1
  73. package/src/builder/webpack/analyzePlugins/rsdoctor.ts +0 -2
  74. package/src/builder/webpack/analyzePlugins/statoscope.ts +8 -40
  75. package/src/builder/webpack/analyzePlugins/stats.ts +45 -0
  76. package/src/builder/webpack/analyzePlugins/whyBundled.ts +1 -1
  77. package/src/builder/webpack/providers/build/server.ts +7 -2
  78. package/src/builder/webpack/providers/shared.ts +2 -0
  79. package/src/builder/webpack/providers/start/shared.ts +10 -4
  80. package/src/builder/webpack/types.ts +5 -2
  81. package/src/commands/analyze/command.ts +1 -1
  82. package/src/commands/build/command.ts +6 -1
  83. package/src/commands/start/command.ts +1 -1
  84. package/src/config/configManager.ts +3 -1
  85. package/src/library/swc/__integration__/__snapshots__/swc.build.test.ts.snap +14 -14
  86. package/src/library/swc/__integration__/__snapshots__/swc.start.test.ts.snap +30 -30
  87. package/src/library/swc/__integration__/swc.build.test.ts +1 -1
  88. package/src/library/swc/__integration__/swc.start.test.ts +1 -1
  89. package/src/library/webpack/blocks/js.ts +1 -2
  90. package/src/library/webpack/blocks/optimize.ts +8 -1
  91. package/src/library/webpack/child-app/common.ts +2 -10
  92. package/src/library/webpack/common/main.ts +1 -1
  93. package/src/models/config.spec.ts +0 -4
  94. package/src/schema/autogeneratedSchema.json +15 -30
  95. package/src/schema/tramvai.spec.ts +0 -2
  96. package/src/typings/configEntry/cli.ts +0 -5
@@ -5,8 +5,6 @@ type options = ConstructorParameters<typeof RsdoctorWebpackPlugin<[]>>;
5
5
  export class RsdoctorAnalyzePlugin extends AnalyzePlugin {
6
6
  requireDeps = [];
7
7
 
8
- options: options = [];
9
-
10
8
  // rsdoctor поднимает dev server
11
9
  afterBuild = () => new Promise(() => null);
12
10
 
@@ -1,50 +1,18 @@
1
- import chalk from 'chalk';
1
+ import type StatoscopeWebpackPlugin from '@statoscope/webpack-plugin';
2
+
2
3
  import { AnalyzePlugin } from '../types';
3
- import type { FileStatsOptions } from '../../../library/webpack/plugins/FileStats';
4
- import { FileStatsPlugin } from '../../../library/webpack/plugins/FileStats';
5
4
 
6
5
  export class StatoscopeAnalyzePlugin extends AnalyzePlugin {
7
- statsFileName = 'stats-all.json';
8
-
9
6
  requireDeps = [];
10
7
 
11
- statsFilePath: string;
12
-
13
- options: [FileStatsOptions] = [
8
+ options = (): ConstructorParameters<typeof StatoscopeWebpackPlugin> => [
14
9
  {
15
- filename: this.statsFileName,
16
- stats: {
17
- hash: true, // add compilation hash
18
- entrypoints: true, // add entrypoints stats
19
- chunks: true, // add chunks stats
20
- chunkModules: true, // add modules stats
21
- reasons: true, // add modules reasons stats
22
-
23
- assets: true, // add assets stats
24
- chunkOrigins: true, // add chunks origins stats (to find out which modules require a chunk)
25
- version: true, // add webpack version
26
- builtAt: true, // add build at time
27
- timings: true, // add build at time
28
- performance: true, // add info about oversized assets
29
- source: true, // add module sources (uses to find modules duplicates)
30
- },
10
+ statsOptions: { all: true },
31
11
  },
32
12
  ];
33
13
 
34
- plugin = FileStatsPlugin;
35
-
36
- afterBuild = () => {
37
- console.log(
38
- chalk.yellow(
39
- `Приложение собралось и корне проекта доступен файл со всей информацией по приложению в файле ${this.statsFileName}`
40
- )
41
- );
42
- console.log(
43
- chalk.green(
44
- `Далее необходимо зайти на страницу https://statoscope.tech/ и drag-on-drop перенести файл из клиентских ассетов ${this.statsFileName}`
45
- )
46
- );
47
-
48
- return Promise.resolve();
49
- };
14
+ get plugin() {
15
+ // eslint-disable-next-line import/no-unresolved
16
+ return require('@statoscope/webpack-plugin').default;
17
+ }
50
18
  }
@@ -0,0 +1,45 @@
1
+ import chalk from 'chalk';
2
+ import { AnalyzePlugin } from '../types';
3
+ import type { FileStatsOptions } from '../../../library/webpack/plugins/FileStats';
4
+ import { FileStatsPlugin } from '../../../library/webpack/plugins/FileStats';
5
+
6
+ export class StatsAnalyzePlugin extends AnalyzePlugin {
7
+ statsFileName = 'stats-all.json';
8
+
9
+ requireDeps = [];
10
+
11
+ statsFilePath: string;
12
+
13
+ options = (): [FileStatsOptions] => [
14
+ {
15
+ filename: this.statsFileName,
16
+ stats: {
17
+ hash: true, // add compilation hash
18
+ entrypoints: true, // add entrypoints stats
19
+ chunks: true, // add chunks stats
20
+ chunkModules: true, // add modules stats
21
+ reasons: true, // add modules reasons stats
22
+
23
+ assets: true, // add assets stats
24
+ chunkOrigins: true, // add chunks origins stats (to find out which modules require a chunk)
25
+ version: true, // add webpack version
26
+ builtAt: true, // add build at time
27
+ timings: true, // add build at time
28
+ performance: true, // add info about oversized assets
29
+ source: true, // add module sources (uses to find modules duplicates)
30
+ },
31
+ },
32
+ ];
33
+
34
+ plugin = FileStatsPlugin;
35
+
36
+ afterBuild = () => {
37
+ console.log(
38
+ chalk.yellow(
39
+ `Сборка завершилась успешна, сгенерирвао файл с информацией о сборке ${this.statsFileName}`
40
+ )
41
+ );
42
+
43
+ return Promise.resolve();
44
+ };
45
+ }
@@ -12,7 +12,7 @@ export class WhyBundledAnalyzePlugin extends AnalyzePlugin {
12
12
  statsFilePath: string;
13
13
 
14
14
  plugin = FileStatsPlugin;
15
- options: [FileStatsOptions] = [
15
+ options = (): [FileStatsOptions] => [
16
16
  {
17
17
  filename: this.statsFileName,
18
18
  stats: {
@@ -9,6 +9,7 @@ import {
9
9
  PROCESS_HANDLER_TOKEN,
10
10
  SERVER_CONFIG_MANAGER_TOKEN,
11
11
  WEBPACK_ANALYZE_PLUGIN_TOKEN,
12
+ WEBPACK_CLIENT_CONFIG_TOKEN,
12
13
  WEBPACK_SERVER_COMPILER_TOKEN,
13
14
  WEBPACK_SERVER_CONFIG_TOKEN,
14
15
  } from '../../tokens';
@@ -19,15 +20,19 @@ import { createCompiler } from '../../utils/compiler';
19
20
  export const buildServerProviders: Provider[] = [
20
21
  provide({
21
22
  provide: WEBPACK_SERVER_COMPILER_TOKEN,
22
- useFactory: ({ webpackConfig, di, analyzePlugin }) => {
23
+ useFactory: ({ webpackConfig, di, analyzePlugin, clientConfig }) => {
24
+ // analyze server only if no client build found
25
+ const shouldAnalyze = !clientConfig && analyzePlugin;
26
+
23
27
  return createCompiler(
24
- toWebpackConfig(analyzePlugin ? analyzePlugin.patchConfig(webpackConfig) : webpackConfig),
28
+ toWebpackConfig(shouldAnalyze ? analyzePlugin.patchConfig(webpackConfig) : webpackConfig),
25
29
  di
26
30
  );
27
31
  },
28
32
  deps: {
29
33
  webpackConfig: WEBPACK_SERVER_CONFIG_TOKEN,
30
34
  di: DI_TOKEN,
35
+ clientConfig: { token: WEBPACK_CLIENT_CONFIG_TOKEN, optional: true },
31
36
  analyzePlugin: { token: WEBPACK_ANALYZE_PLUGIN_TOKEN, optional: true },
32
37
  },
33
38
  }),
@@ -19,6 +19,7 @@ import { BundleAnalyzePlugin } from '../analyzePlugins/bundle';
19
19
  import { StatoscopeAnalyzePlugin } from '../analyzePlugins/statoscope';
20
20
  import { WhyBundledAnalyzePlugin } from '../analyzePlugins/whyBundled';
21
21
  import { RsdoctorAnalyzePlugin } from '../analyzePlugins/rsdoctor';
22
+ import { StatsAnalyzePlugin } from '../analyzePlugins/stats';
22
23
  import type { AnalyzePlugin } from '../types';
23
24
 
24
25
  interface Type<T> extends Function {
@@ -29,6 +30,7 @@ const pluginMap: Record<string, Type<AnalyzePlugin>> = {
29
30
  bundle: BundleAnalyzePlugin,
30
31
  whybundled: WhyBundledAnalyzePlugin,
31
32
  statoscope: StatoscopeAnalyzePlugin,
33
+ stats: StatsAnalyzePlugin,
32
34
  rsdoctor: RsdoctorAnalyzePlugin,
33
35
  };
34
36
 
@@ -18,10 +18,16 @@ export const startSharedProviders: Provider[] = [
18
18
  provide({
19
19
  provide: WEBPACK_COMPILER_TOKEN,
20
20
  useFactory: ({ clientConfig, serverConfig, analyzePlugin }) => {
21
- const configs = [clientConfig, serverConfig]
22
- .filter(Boolean)
23
- .map((config) => (analyzePlugin ? analyzePlugin.patchConfig(config) : config))
24
- .map(toWebpackConfig);
21
+ if (analyzePlugin) {
22
+ // analyze server only if no client build found
23
+ if (clientConfig) {
24
+ analyzePlugin.patchConfig(clientConfig);
25
+ } else {
26
+ analyzePlugin.patchConfig(serverConfig);
27
+ }
28
+ }
29
+
30
+ const configs = [clientConfig, serverConfig].filter(Boolean).map(toWebpackConfig);
25
31
  const multiCompiler = webpack(configs);
26
32
  const { inputFileSystem } = multiCompiler.compilers[0];
27
33
 
@@ -1,4 +1,6 @@
1
1
  import type Config from 'webpack-chain';
2
+ import { Configuration } from 'webpack';
3
+
2
4
  import type { ConfigManager } from '../../config/configManager';
3
5
 
4
6
  export type ConfigGenerator = (arg: {
@@ -9,7 +11,7 @@ export type ConfigGenerator = (arg: {
9
11
  export abstract class AnalyzePlugin {
10
12
  requireDeps?: string[];
11
13
 
12
- protected options?;
14
+ protected options?: (webpackConfig: Configuration) => any[] = () => [];
13
15
 
14
16
  protected abstract plugin;
15
17
 
@@ -24,7 +26,8 @@ export abstract class AnalyzePlugin {
24
26
  };
25
27
 
26
28
  protected patchConfigInternal(config: Config): Config {
27
- config.plugin('analyze').use(this.plugin, this.options);
29
+ const pureWebpackConfig = config.toConfig();
30
+ config.plugin('analyze').use(this.plugin, this.options(pureWebpackConfig));
28
31
 
29
32
  return config;
30
33
  }
@@ -17,7 +17,7 @@ class AnalyzeCommand extends CLICommand<Params> {
17
17
  {
18
18
  name: '-p, --plugin',
19
19
  value: '[plugin]',
20
- description: 'Analysis plugin type <bundle|whybundled|statoscope|rsdoctor>',
20
+ description: 'Analysis plugin type <bundle|whybundled|statoscope|rsdoctor|stats>',
21
21
  defaultValue: 'bundle',
22
22
  },
23
23
  {
@@ -32,6 +32,11 @@ class BuildCommand extends CLICommand<Params> {
32
32
  value: '[disableProdOptimization]',
33
33
  description: 'Disable optimization of bundle sizes for production (minification, etc.)',
34
34
  },
35
+ {
36
+ name: '--readableOutput',
37
+ value: '[readableOutput]',
38
+ description: 'Disable hashed names and concatenated modules for better debug/analyze purpose',
39
+ },
35
40
  {
36
41
  name: '--showConfig',
37
42
  value: '[showConfig]',
@@ -51,7 +56,7 @@ class BuildCommand extends CLICommand<Params> {
51
56
  name: '--analyze',
52
57
  value: '[analyze]',
53
58
  description:
54
- 'Run build with analyze, supported plugins: <bundle|whybundled|statoscope|rsdoctor>',
59
+ 'Run build with analyze, supported plugins: <bundle|whybundled|statoscope|rsdoctor|stats>',
55
60
  },
56
61
  {
57
62
  name: '--fileCache',
@@ -92,7 +92,7 @@ export class StartCommand extends CLICommand<Params> {
92
92
  name: '--analyze',
93
93
  value: '[analyze]',
94
94
  description:
95
- 'Run build with analyze, supported plugins: <bundle|whybundled|statoscope|rsdoctor>',
95
+ 'Run build with analyze, supported plugins: <bundle|whybundled|statoscope|rsdoctor|stats>',
96
96
  },
97
97
  {
98
98
  name: '--onlyBundles',
@@ -41,8 +41,9 @@ export interface Settings<E extends Env> {
41
41
  resolveSymlinks?: boolean;
42
42
  showConfig?: boolean;
43
43
  onlyBundles?: string[];
44
- analyze?: false | 'bundle' | 'whybundled' | 'statoscope' | 'rsdoctor';
44
+ analyze?: false | 'bundle' | 'whybundled' | 'statoscope' | 'rsdoctor' | 'stats';
45
45
  disableProdOptimization?: boolean;
46
+ readableOutput?: boolean;
46
47
  fileCache?: boolean;
47
48
  }
48
49
 
@@ -136,6 +137,7 @@ export const createConfigManager = <C extends ConfigEntry = ConfigEntry, E exten
136
137
  benchmark: false,
137
138
  resolveSymlinks: true,
138
139
  disableProdOptimization: false,
140
+ readableOutput: false,
139
141
  analyze: false,
140
142
  onlyBundles: [],
141
143
  // according to measures fileCache in webpack doesn't affect
@@ -8,7 +8,7 @@ exports[`client: create-token-pure.ts 1`] = `
8
8
  /* binding */ return TEST_TOKEN;
9
9
  }
10
10
  /* harmony export */ });
11
- const TEST_TOKEN = /*#__PURE__*/ /*#__PURE__*/ (0, __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts").E)("TEST_TOKEN");
11
+ const TEST_TOKEN = /*#__PURE__*/ /*#__PURE__*/ (0, __webpack_require__("./mocks/tramvai-core.ts").E)("TEST_TOKEN");
12
12
  "
13
13
  `;
14
14
 
@@ -73,7 +73,7 @@ exports[`client: lazy-component.tsx 1`] = `
73
73
  }
74
74
  /* harmony export */ });
75
75
  /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime");
76
- /* harmony import */ const LazyComponent = (0, __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-react.ts").R)({
76
+ /* harmony import */ const LazyComponent = (0, __webpack_require__("./mocks/tramvai-react.ts").R)({
77
77
  chunkName: () => "components-lazy-inner",
78
78
  requireSync(props) {
79
79
  return __webpack_require__(this.resolve(props));
@@ -82,11 +82,11 @@ exports[`client: lazy-component.tsx 1`] = `
82
82
  const key = this.resolve(props);
83
83
  return !!__webpack_require__.m[key];
84
84
  },
85
- importAsync: () => __webpack_require__.e(/* import() | components-lazy-inner */ "components-lazy-inner").then(__webpack_require__.bind(__webpack_require__, "./src/library/swc/__integration__/components/lazy-inner.tsx")),
85
+ importAsync: () => __webpack_require__.e(/* import() | components-lazy-inner */ "components-lazy-inner").then(__webpack_require__.bind(__webpack_require__, "./components/lazy-inner.tsx")),
86
86
  requireAsync(props) {
87
87
  return this.importAsync(props).then(resolved => resolved);
88
88
  },
89
- resolve: () => /*require.resolve*/ "./src/library/swc/__integration__/components/lazy-inner.tsx"
89
+ resolve: () => /*require.resolve*/ "./components/lazy-inner.tsx"
90
90
  }), Component = () => /*#__PURE__*/ /*#__PURE__*/ (0, react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
91
91
  children: [
92
92
  /*#__PURE__*/
@@ -121,7 +121,7 @@ exports[`client: provider-stack.ts 1`] = `
121
121
  /* binding */ return providers;
122
122
  }
123
123
  /* harmony export */ });
124
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts"), _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/create-token-pure.ts");
124
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts"), _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./create-token-pure.ts");
125
125
  /* harmony import */ const providers = [ (0, _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ /* .provide */ .G)({
126
126
  provide: _create_token_pure__WEBPACK_IMPORTED_MODULE_1__.TEST_TOKEN,
127
127
  useValue: "test"
@@ -137,7 +137,7 @@ exports[`client: react-svg.tsx 1`] = `
137
137
  /* binding */ return Component;
138
138
  }
139
139
  /* harmony export */ });
140
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/images/logo.svg?react");
140
+ /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./images/logo.svg?react");
141
141
  /* harmony import */ const Component = () => /*#__PURE__*/ /*#__PURE__*/ (0,
142
142
  react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)("div", {
143
143
  children: /*#__PURE__*/ /*#__PURE__*/ (0 /* ["default"] */ , react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__.A, {})
@@ -153,7 +153,7 @@ exports[`client: server.inline.ts 1`] = `
153
153
  /* binding */ return ForBrowser;
154
154
  }
155
155
  /* harmony export */ });
156
- /* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../../node_modules/@swc/helpers/esm/_define_property.js");
156
+ /* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../../../../../../node_modules/@swc/helpers/esm/_define_property.js");
157
157
  class ForBrowser {
158
158
  test() {
159
159
  console.log("Ok");
@@ -189,7 +189,7 @@ exports[`server: create-token-pure.ts 1`] = `
189
189
  /* binding */ return TEST_TOKEN;
190
190
  }
191
191
  /* harmony export */ });
192
- const TEST_TOKEN = /*#__PURE__*/ /*#__PURE__*/ (0, __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts").E)("TEST_TOKEN");
192
+ const TEST_TOKEN = /*#__PURE__*/ /*#__PURE__*/ (0, __webpack_require__("./mocks/tramvai-core.ts").E)("TEST_TOKEN");
193
193
  "
194
194
  `;
195
195
 
@@ -251,8 +251,8 @@ exports[`server: lazy-component.tsx 1`] = `
251
251
  /* binding */ return Component;
252
252
  }
253
253
  /* harmony export */ });
254
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _swc_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../../node_modules/@swc/helpers/esm/_interop_require_wildcard.js");
255
- /* harmony import */ const LazyComponent = (0, __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-react.ts").R)({
254
+ /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _swc_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../../../../../../node_modules/@swc/helpers/esm/_interop_require_wildcard.js");
255
+ /* harmony import */ const LazyComponent = (0, __webpack_require__("./mocks/tramvai-react.ts").R)({
256
256
  chunkName() {
257
257
  return "components-lazy-inner";
258
258
  },
@@ -263,13 +263,13 @@ exports[`server: lazy-component.tsx 1`] = `
263
263
  const key = this.resolve(props);
264
264
  return !!__webpack_require__.m[key];
265
265
  },
266
- importAsync: () => Promise.resolve().then(() => (0, _swc_helpers__WEBPACK_IMPORTED_MODULE_1__._)(__webpack_require__(/* webpackChunkName: "components-lazy-inner" */ "./src/library/swc/__integration__/components/lazy-inner.tsx"))),
266
+ importAsync: () => Promise.resolve().then(() => (0, _swc_helpers__WEBPACK_IMPORTED_MODULE_1__._)(__webpack_require__(/* webpackChunkName: "components-lazy-inner" */ "./components/lazy-inner.tsx"))),
267
267
  requireAsync(props) {
268
268
  return this.importAsync(props).then(resolved => resolved);
269
269
  },
270
270
  resolve() {
271
271
  /*require.resolve*/
272
- return "./src/library/swc/__integration__/components/lazy-inner.tsx";
272
+ return "./components/lazy-inner.tsx";
273
273
  }
274
274
  }), Component = () => /*#__PURE__*/ /*#__PURE__*/ (0, react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
275
275
  children: [
@@ -303,7 +303,7 @@ exports[`server: provider-stack.ts 1`] = `
303
303
  /* binding */ return providers;
304
304
  }
305
305
  /* harmony export */ });
306
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts"), _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/create-token-pure.ts");
306
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts"), _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./create-token-pure.ts");
307
307
  /* harmony import */ const providers = [ (0, _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ /* .provide */ .G)({
308
308
  provide: _create_token_pure__WEBPACK_IMPORTED_MODULE_1__.TEST_TOKEN,
309
309
  useValue: "test"
@@ -318,7 +318,7 @@ exports[`server: react-svg.tsx 1`] = `
318
318
  /* binding */ return Component;
319
319
  }
320
320
  /* harmony export */ });
321
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/images/logo.svg?react");
321
+ /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-runtime/react/jsx-runtime"), _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./images/logo.svg?react");
322
322
  /* harmony import */ const Component = () => /*#__PURE__*/ /*#__PURE__*/ (0,
323
323
  react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)("div", {
324
324
  children: /*#__PURE__*/ /*#__PURE__*/ (0 /* ["default"] */ , react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx)(_images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__.A, {})
@@ -5,9 +5,9 @@ exports[`client: create-token-pure.ts 1`] = `
5
5
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
6
6
  /* harmony export */ TEST_TOKEN: function() { return /* binding */ TEST_TOKEN; }
7
7
  /* harmony export */ });
8
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts");
9
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
10
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
8
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts");
9
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
10
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
11
11
 
12
12
 
13
13
  const TEST_TOKEN = /*#__PURE__*/ (0,_tramvai_core__WEBPACK_IMPORTED_MODULE_0__.createToken)('TEST_TOKEN');
@@ -139,9 +139,9 @@ exports[`client: lazy-component.tsx 1`] = `
139
139
  /* harmony export */ });
140
140
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-dev-runtime/react/jsx-dev-runtime");
141
141
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__);
142
- /* harmony import */ var _tramvai_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-react.ts");
143
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
144
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
142
+ /* harmony import */ var _tramvai_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./mocks/tramvai-react.ts");
143
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
144
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
145
145
 
146
146
 
147
147
 
@@ -156,12 +156,12 @@ const LazyComponent = (0,_tramvai_react__WEBPACK_IMPORTED_MODULE_1__.lazy)({
156
156
  const key = this.resolve(props);
157
157
  return !!__webpack_require__.m[key];
158
158
  },
159
- importAsync: ()=>__webpack_require__.e(/* import() | components-lazy-inner */ "components-lazy-inner").then(__webpack_require__.bind(__webpack_require__, "./src/library/swc/__integration__/components/lazy-inner.tsx")),
159
+ importAsync: ()=>__webpack_require__.e(/* import() | components-lazy-inner */ "components-lazy-inner").then(__webpack_require__.bind(__webpack_require__, "./components/lazy-inner.tsx")),
160
160
  requireAsync (props) {
161
161
  return this.importAsync(props).then((resolved)=>resolved);
162
162
  },
163
163
  resolve () {
164
- return /*require.resolve*/("./src/library/swc/__integration__/components/lazy-inner.tsx");
164
+ return /*require.resolve*/("./components/lazy-inner.tsx");
165
165
  }
166
166
  });
167
167
  _c = LazyComponent;
@@ -228,8 +228,8 @@ exports[`client: node-env.ts 1`] = `
228
228
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
229
229
  /* harmony export */ func: function() { return /* binding */ func; }
230
230
  /* harmony export */ });
231
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
232
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
231
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
232
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
233
233
 
234
234
  let internalFunc;
235
235
  if (true) {
@@ -281,10 +281,10 @@ exports[`client: provider-stack.ts 1`] = `
281
281
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
282
282
  /* harmony export */ providers: function() { return /* binding */ providers; }
283
283
  /* harmony export */ });
284
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts");
285
- /* harmony import */ var _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/create-token-pure.ts");
286
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
287
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
284
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts");
285
+ /* harmony import */ var _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./create-token-pure.ts");
286
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
287
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
288
288
 
289
289
  var _ref;
290
290
 
@@ -341,9 +341,9 @@ exports[`client: react-svg.tsx 1`] = `
341
341
  /* harmony export */ });
342
342
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-dev-runtime/react/jsx-dev-runtime");
343
343
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__);
344
- /* harmony import */ var _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/images/logo.svg?react");
345
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
346
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
344
+ /* harmony import */ var _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./images/logo.svg?react");
345
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
346
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
347
347
 
348
348
 
349
349
 
@@ -404,9 +404,9 @@ exports[`client: server.inline.ts 1`] = `
404
404
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
405
405
  /* harmony export */ ForBrowser: function() { return /* binding */ ForBrowser; }
406
406
  /* harmony export */ });
407
- /* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../../node_modules/@swc/helpers/esm/_define_property.js");
408
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
409
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
407
+ /* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../../../../../../node_modules/@swc/helpers/esm/_define_property.js");
408
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
409
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
410
410
 
411
411
 
412
412
  class ForBrowser {
@@ -461,8 +461,8 @@ exports[`client: typeof-window.ts 1`] = `
461
461
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
462
462
  /* harmony export */ func: function() { return /* binding */ func; }
463
463
  /* harmony export */ });
464
- /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
465
- __webpack_require__.$Refresh$.runtime = __webpack_require__("../../node_modules/react-refresh/runtime.js");
464
+ /* provided dependency */ var __react_refresh_utils__ = __webpack_require__("../../../../../../node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime/RefreshUtils.js");
465
+ __webpack_require__.$Refresh$.runtime = __webpack_require__("../../../../../../node_modules/react-refresh/runtime.js");
466
466
 
467
467
  let internalFunc;
468
468
  if (true) {
@@ -514,7 +514,7 @@ exports[`server: create-token-pure.ts 1`] = `
514
514
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
515
515
  /* harmony export */ TEST_TOKEN: function() { return /* binding */ TEST_TOKEN; }
516
516
  /* harmony export */ });
517
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts");
517
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts");
518
518
 
519
519
  const TEST_TOKEN = /*#__PURE__*/ (0,_tramvai_core__WEBPACK_IMPORTED_MODULE_0__.createToken)('TEST_TOKEN');
520
520
 
@@ -611,8 +611,8 @@ exports[`server: lazy-component.tsx 1`] = `
611
611
  /* harmony export */ });
612
612
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-dev-runtime/react/jsx-dev-runtime");
613
613
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__);
614
- /* harmony import */ var _swc_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../../node_modules/@swc/helpers/esm/_interop_require_wildcard.js");
615
- /* harmony import */ var _tramvai_react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-react.ts");
614
+ /* harmony import */ var _swc_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../../../../../../node_modules/@swc/helpers/esm/_interop_require_wildcard.js");
615
+ /* harmony import */ var _tramvai_react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./mocks/tramvai-react.ts");
616
616
 
617
617
 
618
618
 
@@ -627,12 +627,12 @@ const LazyComponent = (0,_tramvai_react__WEBPACK_IMPORTED_MODULE_2__.lazy)({
627
627
  const key = this.resolve(props);
628
628
  return !!__webpack_require__.m[key];
629
629
  },
630
- importAsync: ()=>Promise.resolve().then(()=>(0,_swc_helpers__WEBPACK_IMPORTED_MODULE_1__._)(__webpack_require__(/* webpackChunkName: "components-lazy-inner" */ "./src/library/swc/__integration__/components/lazy-inner.tsx"))),
630
+ importAsync: ()=>Promise.resolve().then(()=>(0,_swc_helpers__WEBPACK_IMPORTED_MODULE_1__._)(__webpack_require__(/* webpackChunkName: "components-lazy-inner" */ "./components/lazy-inner.tsx"))),
631
631
  requireAsync (props) {
632
632
  return this.importAsync(props).then((resolved)=>resolved);
633
633
  },
634
634
  resolve () {
635
- return /*require.resolve*/("./src/library/swc/__integration__/components/lazy-inner.tsx");
635
+ return /*require.resolve*/("./components/lazy-inner.tsx");
636
636
  }
637
637
  });
638
638
  const Component = ()=>{
@@ -682,8 +682,8 @@ exports[`server: provider-stack.ts 1`] = `
682
682
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
683
683
  /* harmony export */ providers: function() { return /* binding */ providers; }
684
684
  /* harmony export */ });
685
- /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/library/swc/__integration__/mocks/tramvai-core.ts");
686
- /* harmony import */ var _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/create-token-pure.ts");
685
+ /* harmony import */ var _tramvai_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./mocks/tramvai-core.ts");
686
+ /* harmony import */ var _create_token_pure__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./create-token-pure.ts");
687
687
  var _ref;
688
688
 
689
689
 
@@ -708,7 +708,7 @@ exports[`server: react-svg.tsx 1`] = `
708
708
  /* harmony export */ });
709
709
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("webpack/sharing/consume/default/react/jsx-dev-runtime/react/jsx-dev-runtime");
710
710
  /* harmony import */ var react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_dev_runtime__WEBPACK_IMPORTED_MODULE_0__);
711
- /* harmony import */ var _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/library/swc/__integration__/images/logo.svg?react");
711
+ /* harmony import */ var _images_logo_svg_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./images/logo.svg?react");
712
712
 
713
713
 
714
714
  const Component = ()=>{
@@ -6,7 +6,7 @@ let clientCode: string;
6
6
  let serverCode: string;
7
7
 
8
8
  const getModuleCode = (code: string, name: string) => {
9
- const regexp = new RegExp(`swc/__integration__/${name}":\\s*\n.+?{\n(.+?)/\\*{3}/\\s`, 's');
9
+ const regexp = new RegExp(`\\./${name}":\\s*\n.+?{\n(.+?)/\\*{3}/\\s`, 's');
10
10
 
11
11
  const match = code.match(regexp);
12
12
 
@@ -15,7 +15,7 @@ const normalizeCode = (code: string) => {
15
15
  };
16
16
 
17
17
  const getModuleCode = (code: string, name: string) => {
18
- const regexp = new RegExp(`swc/__integration__/${name}":.+?eval\\("{(.+?)//# sourceURL=`, 's');
18
+ const regexp = new RegExp(`\\./${name}":.+?eval\\("{(.+?)//# sourceURL=`, 's');
19
19
 
20
20
  const match = code.match(regexp);
21
21
 
@@ -32,9 +32,8 @@ const applyNodeModulesRules = (rule, configManager) => {
32
32
 
33
33
  // eslint-disable-next-line import/no-default-export
34
34
  export default (configManager: ConfigManager<CliConfigEntry>) => (config: Config) => {
35
- const { transpileOnlyModernLibs } = configManager;
36
35
  const { include } = configManager.experiments.transpilation;
37
- const shouldTranspileOnlyModern = transpileOnlyModernLibs || include === 'only-modern';
36
+ const shouldTranspileOnlyModern = include === 'only-modern';
38
37
 
39
38
  const rule = config.module
40
39
  .rule('js')
@@ -6,7 +6,7 @@ import type { ConfigManager } from '../../../config/configManager';
6
6
  import type { CliConfigEntry } from '../../../typings/configEntry/cli';
7
7
 
8
8
  export default (configManager: ConfigManager<CliConfigEntry>) => (config: Config) => {
9
- const { debug, disableProdOptimization } = configManager;
9
+ const { debug, disableProdOptimization, readableOutput } = configManager;
10
10
 
11
11
  const isProductionProfilingEnabled = !!process.env.TRAMVAI_REACT_PROFILE;
12
12
  const tramvaiReactProfileTerserOptions = {
@@ -51,6 +51,13 @@ export default (configManager: ConfigManager<CliConfigEntry>) => (config: Config
51
51
  return;
52
52
  }
53
53
 
54
+ if (readableOutput) {
55
+ // with this option for id of module path to file will be used
56
+ config.optimization.set('moduleIds', 'named');
57
+ // prevent modules from concatenation in single module to easier debug
58
+ config.optimization.set('concatenateModules', false);
59
+ }
60
+
54
61
  const { terser } = configManager;
55
62
 
56
63
  config.plugin('terser').use(TerserPlugin, [