@modern-js/plugin-testing 0.0.0-next-1687334871558 → 0.0.0-next-1687370848744

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
@@ -1,17 +1,31 @@
1
1
  # @modern-js/plugin-testing
2
2
 
3
- ## 0.0.0-next-1687334871558
3
+ ## 0.0.0-next-1687370848744
4
4
 
5
5
  ### Patch Changes
6
6
 
7
- - Updated dependencies [c882fbd269]
8
- - Updated dependencies [56693a3ebe]
9
- - Updated dependencies [4a82c3ba1b]
10
- - @modern-js/runtime@0.0.0-next-1687334871558
11
- - @modern-js/utils@0.0.0-next-1687334871558
12
- - @modern-js/prod-server@0.0.0-next-1687334871558
13
- - @modern-js/babel-compiler@0.0.0-next-1687334871558
14
- - @modern-js/plugin@0.0.0-next-1687334871558
7
+ - 4c4c0ade4: feat: add named exports for all CLI plugins
8
+
9
+ feat: 为各个 CLI 插件添加 named 导出
10
+
11
+ - @modern-js/runtime@0.0.0-next-1687370848744
12
+ - @modern-js/prod-server@0.0.0-next-1687370848744
13
+ - @modern-js/babel-compiler@0.0.0-next-1687370848744
14
+ - @modern-js/plugin@0.0.0-next-1687370848744
15
+ - @modern-js/utils@0.0.0-next-1687370848744
16
+
17
+ ## 2.24.0
18
+
19
+ ### Patch Changes
20
+
21
+ - Updated dependencies [c882fbd]
22
+ - Updated dependencies [56693a3]
23
+ - Updated dependencies [4a82c3b]
24
+ - @modern-js/runtime@2.24.0
25
+ - @modern-js/utils@2.24.0
26
+ - @modern-js/prod-server@2.24.0
27
+ - @modern-js/babel-compiler@2.24.0
28
+ - @modern-js/plugin@2.24.0
15
29
 
16
30
  ## 2.23.1
17
31
 
@@ -13,8 +13,8 @@ _export(exports, {
13
13
  setJestConfigForBFF: function() {
14
14
  return setJestConfigForBFF;
15
15
  },
16
- default: function() {
17
- return _default;
16
+ testingBffPlugin: function() {
17
+ return testingBffPlugin;
18
18
  }
19
19
  });
20
20
  const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
@@ -109,7 +109,7 @@ const setJestConfigForBFF = async ({ pwd, userConfig, plugins, routes, utils })
109
109
  }
110
110
  utils.setJestConfig(commonConfig);
111
111
  };
112
- const _default = () => ({
112
+ const testingBffPlugin = () => ({
113
113
  name: "@modern-js/testing-plugin-bff",
114
114
  setup(api) {
115
115
  return {
@@ -13,6 +13,9 @@ _export(exports, {
13
13
  mergeUserJestConfig: function() {
14
14
  return mergeUserJestConfig;
15
15
  },
16
+ testingPlugin: function() {
17
+ return testingPlugin;
18
+ },
16
19
  default: function() {
17
20
  return _default;
18
21
  }
@@ -22,7 +25,7 @@ const _path = /* @__PURE__ */ _interop_require_default._(require("path"));
22
25
  const _utils = require("@modern-js/utils");
23
26
  const _base = require("../base");
24
27
  const _constant = require("../constant");
25
- const _bff = /* @__PURE__ */ _interop_require_default._(require("./bff"));
28
+ const _bff = require("./bff");
26
29
  const _test = /* @__PURE__ */ _interop_require_default._(require("./test"));
27
30
  const mergeUserJestConfig = (testUtils) => {
28
31
  const resolveJestConfig = testUtils.testConfig.jest;
@@ -30,8 +33,8 @@ const mergeUserJestConfig = (testUtils) => {
30
33
  testUtils.mergeJestConfig(resolveJestConfig);
31
34
  }
32
35
  };
33
- const _default = () => {
34
- const bffPlugin = (0, _bff.default)();
36
+ const testingPlugin = () => {
37
+ const bffPlugin = (0, _bff.testingBffPlugin)();
35
38
  return {
36
39
  name: "@modern-js/plugin-testing",
37
40
  usePlugins: [
@@ -123,3 +126,4 @@ const _default = () => {
123
126
  }
124
127
  };
125
128
  };
129
+ const _default = testingPlugin;
@@ -103,7 +103,7 @@ export var setJestConfigForBFF = function() {
103
103
  return _ref.apply(this, arguments);
104
104
  };
105
105
  }();
106
- export default function() {
106
+ export var testingBffPlugin = function() {
107
107
  return {
108
108
  name: "@modern-js/testing-plugin-bff",
109
109
  setup: function setup(api) {
@@ -149,5 +149,4 @@ export default function() {
149
149
  };
150
150
  }
151
151
  };
152
- }
153
- ;
152
+ };
@@ -5,7 +5,7 @@ import path from "path";
5
5
  import { isApiOnly, mergeAlias, createRuntimeExportsUtils } from "@modern-js/utils";
6
6
  import { testingHooks, getModuleNameMapper, DEFAULT_RESOLVER_PATH } from "../base";
7
7
  import { MODERNJS_CONFIG_KEY } from "../constant";
8
- import testingBffPlugin from "./bff";
8
+ import { testingBffPlugin } from "./bff";
9
9
  import test from "./test";
10
10
  export var mergeUserJestConfig = function(testUtils) {
11
11
  var resolveJestConfig = testUtils.testConfig.jest;
@@ -13,7 +13,7 @@ export var mergeUserJestConfig = function(testUtils) {
13
13
  testUtils.mergeJestConfig(resolveJestConfig);
14
14
  }
15
15
  };
16
- export default function() {
16
+ export var testingPlugin = function() {
17
17
  var bffPlugin = testingBffPlugin();
18
18
  return {
19
19
  name: "@modern-js/plugin-testing",
@@ -139,5 +139,5 @@ export default function() {
139
139
  };
140
140
  }
141
141
  };
142
- }
143
- ;
142
+ };
143
+ export default testingPlugin;
@@ -89,7 +89,7 @@ export const setJestConfigForBFF = async ({ pwd, userConfig, plugins, routes, ut
89
89
  }
90
90
  utils.setJestConfig(commonConfig);
91
91
  };
92
- export default () => ({
92
+ export const testingBffPlugin = () => ({
93
93
  name: "@modern-js/testing-plugin-bff",
94
94
  setup(api) {
95
95
  return {
@@ -2,7 +2,7 @@ import path from "path";
2
2
  import { isApiOnly, mergeAlias, createRuntimeExportsUtils } from "@modern-js/utils";
3
3
  import { testingHooks, getModuleNameMapper, DEFAULT_RESOLVER_PATH } from "../base";
4
4
  import { MODERNJS_CONFIG_KEY } from "../constant";
5
- import testingBffPlugin from "./bff";
5
+ import { testingBffPlugin } from "./bff";
6
6
  import test from "./test";
7
7
  export const mergeUserJestConfig = (testUtils) => {
8
8
  const resolveJestConfig = testUtils.testConfig.jest;
@@ -10,7 +10,7 @@ export const mergeUserJestConfig = (testUtils) => {
10
10
  testUtils.mergeJestConfig(resolveJestConfig);
11
11
  }
12
12
  };
13
- export default () => {
13
+ export const testingPlugin = () => {
14
14
  const bffPlugin = testingBffPlugin();
15
15
  return {
16
16
  name: "@modern-js/plugin-testing",
@@ -103,3 +103,4 @@ export default () => {
103
103
  }
104
104
  };
105
105
  };
106
+ export default testingPlugin;
@@ -16,9 +16,8 @@ export declare const setJestConfigForBFF: ({
16
16
  routes: any[];
17
17
  utils: TestConfigOperator;
18
18
  }) => Promise<void>;
19
- declare const _default: () => CliPlugin<{
19
+ export declare const testingBffPlugin: () => CliPlugin<{
20
20
  hooks: Hooks;
21
21
  userConfig: UserConfig;
22
22
  normalizedConfig: Required<UserConfig>;
23
- }>;
24
- export default _default;
23
+ }>;
@@ -3,9 +3,9 @@ import { TestConfigOperator } from '../base';
3
3
  import type { Hooks } from '../base/hook';
4
4
  import type { UserConfig } from '../base/config';
5
5
  export declare const mergeUserJestConfig: (testUtils: TestConfigOperator) => void;
6
- declare const _default: () => CliPlugin<{
6
+ export declare const testingPlugin: () => CliPlugin<{
7
7
  hooks: Hooks;
8
8
  userConfig: UserConfig;
9
9
  normalizedConfig: Required<UserConfig>;
10
10
  }>;
11
- export default _default;
11
+ export default testingPlugin;
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "modern",
16
16
  "modern.js"
17
17
  ],
18
- "version": "0.0.0-next-1687334871558",
18
+ "version": "0.0.0-next-1687370848744",
19
19
  "jsnext:source": "./src/cli/index.ts",
20
20
  "types": "./dist/types/cli/index.d.ts",
21
21
  "main": "./dist/cjs/cli/index.js",
@@ -129,15 +129,15 @@
129
129
  "ts-jest": "^29.1.0",
130
130
  "yargs": "^17.0.1",
131
131
  "@swc/helpers": "0.5.1",
132
- "@modern-js/babel-compiler": "0.0.0-next-1687334871558",
133
- "@modern-js/utils": "0.0.0-next-1687334871558",
134
- "@modern-js/plugin": "0.0.0-next-1687334871558",
135
- "@modern-js/prod-server": "0.0.0-next-1687334871558"
132
+ "@modern-js/babel-compiler": "0.0.0-next-1687370848744",
133
+ "@modern-js/plugin": "0.0.0-next-1687370848744",
134
+ "@modern-js/utils": "0.0.0-next-1687370848744",
135
+ "@modern-js/prod-server": "0.0.0-next-1687370848744"
136
136
  },
137
137
  "peerDependencies": {
138
138
  "react": ">=17",
139
139
  "react-dom": ">=17",
140
- "@modern-js/runtime": "0.0.0-next-1687334871558"
140
+ "@modern-js/runtime": "0.0.0-next-1687370848744"
141
141
  },
142
142
  "peerDependenciesMeta": {
143
143
  "@modern-js/runtime": {
@@ -152,12 +152,12 @@
152
152
  "@types/node": "^14",
153
153
  "@types/yargs": "^17.0.2",
154
154
  "typescript": "^5",
155
- "@modern-js/core": "0.0.0-next-1687334871558",
156
- "@modern-js/types": "0.0.0-next-1687334871558",
157
- "@modern-js/bff-core": "0.0.0-next-1687334871558",
158
- "@scripts/build": "0.0.0-next-1687334871558",
159
- "@modern-js/runtime": "0.0.0-next-1687334871558",
160
- "@scripts/jest-config": "0.0.0-next-1687334871558"
155
+ "@modern-js/types": "0.0.0-next-1687370848744",
156
+ "@modern-js/core": "0.0.0-next-1687370848744",
157
+ "@modern-js/runtime": "0.0.0-next-1687370848744",
158
+ "@modern-js/bff-core": "0.0.0-next-1687370848744",
159
+ "@scripts/build": "0.0.0-next-1687370848744",
160
+ "@scripts/jest-config": "0.0.0-next-1687370848744"
161
161
  },
162
162
  "sideEffects": false,
163
163
  "modernConfig": {},