@modern-js/bff-core 1.0.1-beta.6 → 1.1.0-alpha.0

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 ADDED
@@ -0,0 +1,16 @@
1
+ # @modern-js/bff-core
2
+
3
+ ## 1.1.0-alpha.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 77a8e9e1b: feat: support bff operators
8
+
9
+ ### Patch Changes
10
+
11
+ - 7b9e302e2: fix: incorrect @babel/runtime version
12
+ - Updated dependencies [77a8e9e1b]
13
+ - Updated dependencies [9cd364e06]
14
+ - Updated dependencies [a90bc96bd]
15
+ - @modern-js/bff-runtime@1.3.0-alpha.0
16
+ - @modern-js/utils@1.7.9-alpha.0
@@ -47,10 +47,9 @@ export const requireHandlerModule = modulePath => {
47
47
 
48
48
  const {
49
49
  unregister
50
- } = register({}); // 测试环境不走缓存,因为缓存的 handler 文件,会被 mockAPI 函数进行 mock,升级 jest28,setupFilesAfterEnv 能做异步操作的话,可解此问题
50
+ } = register({});
51
51
 
52
- const originRequire = process.env.NODE_ENV === 'test' ? jest.requireActual : require;
53
- const module = originRequire(modulePath);
52
+ const module = require(modulePath);
54
53
 
55
54
  if (isFunction(module)) {
56
55
  return {
@@ -66,10 +66,9 @@ const requireHandlerModule = modulePath => {
66
66
 
67
67
  const {
68
68
  unregister
69
- } = register({}); // 测试环境不走缓存,因为缓存的 handler 文件,会被 mockAPI 函数进行 mock,升级 jest28,setupFilesAfterEnv 能做异步操作的话,可解此问题
69
+ } = register({});
70
70
 
71
- const originRequire = process.env.NODE_ENV === 'test' ? jest.requireActual : require;
72
- const module = originRequire(modulePath);
71
+ const module = require(modulePath);
73
72
 
74
73
  if (isFunction(module)) {
75
74
  return {
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "modern",
12
12
  "modern.js"
13
13
  ],
14
- "version": "1.0.1-beta.6",
14
+ "version": "1.1.0-alpha.0",
15
15
  "jsnext:source": "./src/index.ts",
16
16
  "types": "./dist/types/index.d.ts",
17
17
  "main": "./dist/js/node/index.js",
@@ -24,9 +24,9 @@
24
24
  }
25
25
  },
26
26
  "dependencies": {
27
- "@babel/runtime": "^7.15.4",
28
- "@modern-js/bff-runtime": "^1.2.3",
29
- "@modern-js/utils": "^1.7.6",
27
+ "@babel/runtime": "^7.18.0",
28
+ "@modern-js/bff-runtime": "^1.3.0-alpha.0",
29
+ "@modern-js/utils": "^1.7.9-alpha.0",
30
30
  "esbuild": "^0.14.38",
31
31
  "esbuild-register": "^3.3.3",
32
32
  "koa-compose": "^4.1.0",
@@ -58,8 +58,7 @@
58
58
  },
59
59
  "publishConfig": {
60
60
  "registry": "https://registry.npmjs.org/",
61
- "access": "public",
62
- "types": "./dist/types/index.d.ts"
61
+ "access": "public"
63
62
  },
64
63
  "wireit": {
65
64
  "build": {