@modern-js/core 2.6.0 → 2.7.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 CHANGED
@@ -1,5 +1,28 @@
1
1
  # @modern-js/core
2
2
 
3
+ ## 2.7.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 84bfb439b8: feat: support custom apiDir, lambdaDir and style of writing for bff
8
+ feat: 支持定制 api 目录,lambda 目录,bff 的写法
9
+
10
+ ### Patch Changes
11
+
12
+ - 206c806efa: fix(rspack-provider): missing tools.autoprefixer type
13
+
14
+ fix(rspack-provider): 修复缺少 tools.autoprefixer 类型定义的问题
15
+
16
+ - Updated dependencies [0f15fc597c]
17
+ - Updated dependencies [dcad887024]
18
+ - Updated dependencies [a4672f7c16]
19
+ - Updated dependencies [7fff9020e1]
20
+ - Updated dependencies [1eea234fdd]
21
+ - Updated dependencies [84bfb439b8]
22
+ - @modern-js/utils@2.7.0
23
+ - @modern-js/node-bundle-require@2.7.0
24
+ - @modern-js/plugin@2.7.0
25
+
3
26
  ## 2.6.0
4
27
 
5
28
  ### Patch Changes
package/dist/context.d.ts CHANGED
@@ -26,6 +26,7 @@ export declare const initAppContext: ({ appDirectory, plugins, configFile, optio
26
26
  options?: {
27
27
  metaName?: string | undefined;
28
28
  srcDir?: string | undefined;
29
+ apiDir?: string | undefined;
29
30
  distDir?: string | undefined;
30
31
  sharedDir?: string | undefined;
31
32
  } | undefined;
package/dist/context.js CHANGED
@@ -32,7 +32,7 @@ exports.useConfigContext = useConfigContext;
32
32
  const useResolvedConfigContext = () => exports.ResolvedConfigContext.use().value;
33
33
  exports.useResolvedConfigContext = useResolvedConfigContext;
34
34
  const initAppContext = ({ appDirectory, plugins, configFile, options, serverConfigFile, serverInternalPlugins, toolsType, }) => {
35
- const { metaName = 'modern-js', srcDir = 'src', distDir = '', sharedDir = 'shared', } = options || {};
35
+ const { metaName = 'modern-js', srcDir = 'src', distDir = '', apiDir = 'api', sharedDir = 'shared', } = options || {};
36
36
  return {
37
37
  metaName,
38
38
  appDirectory,
@@ -43,6 +43,8 @@ const initAppContext = ({ appDirectory, plugins, configFile, options, serverConf
43
43
  port: 0,
44
44
  packageName: require(path_1.default.resolve(appDirectory, './package.json')).name,
45
45
  srcDirectory: path_1.default.resolve(appDirectory, srcDir),
46
+ apiDirectory: path_1.default.resolve(appDirectory, apiDir),
47
+ lambdaDirectory: path_1.default.resolve(appDirectory, apiDir, 'lambda'),
46
48
  distDirectory: distDir,
47
49
  sharedDirectory: path_1.default.resolve(appDirectory, sharedDir),
48
50
  nodeModulesDirectory: path_1.default.resolve(appDirectory, './node_modules'),
@@ -13,6 +13,8 @@ export interface IAppContext {
13
13
  toolsType?: ToolsType;
14
14
  packageName: string;
15
15
  srcDirectory: string;
16
+ apiDirectory: string;
17
+ lambdaDirectory: string;
16
18
  sharedDirectory: string;
17
19
  nodeModulesDirectory: string;
18
20
  internalDirectory: string;
package/package.json CHANGED
@@ -10,7 +10,7 @@
10
10
  "modern",
11
11
  "modern.js"
12
12
  ],
13
- "version": "2.6.0",
13
+ "version": "2.7.0",
14
14
  "jsnext:source": "./src/index.ts",
15
15
  "types": "./dist/index.d.ts",
16
16
  "main": "./dist/index.js",
@@ -50,9 +50,9 @@
50
50
  }
51
51
  },
52
52
  "dependencies": {
53
- "@modern-js/node-bundle-require": "2.6.0",
54
- "@modern-js/plugin": "2.6.0",
55
- "@modern-js/utils": "2.6.0"
53
+ "@modern-js/node-bundle-require": "2.7.0",
54
+ "@modern-js/plugin": "2.7.0",
55
+ "@modern-js/utils": "2.7.0"
56
56
  },
57
57
  "devDependencies": {
58
58
  "@jest/types": "^27.0.6",
@@ -61,7 +61,7 @@
61
61
  "@types/jest": "^27",
62
62
  "@types/less": "^3.0.3",
63
63
  "@types/node": "^14",
64
- "autoprefixer": "^10.3.1",
64
+ "autoprefixer": "10.4.13",
65
65
  "btsm": "2.2.2",
66
66
  "html-webpack-plugin": "5.5.0",
67
67
  "jest": "^27",
@@ -70,11 +70,11 @@
70
70
  "terser-webpack-plugin": "^5.1.4",
71
71
  "typescript": "^4",
72
72
  "webpack": "^5.75.0",
73
- "@modern-js/builder-shared": "2.6.0",
74
- "@modern-js/babel-preset-app": "2.6.0",
75
- "@modern-js/types": "2.6.0",
76
- "@scripts/build": "2.6.0",
77
- "@scripts/jest-config": "2.6.0"
73
+ "@modern-js/builder-shared": "2.7.0",
74
+ "@modern-js/babel-preset-app": "2.7.0",
75
+ "@modern-js/types": "2.7.0",
76
+ "@scripts/jest-config": "2.7.0",
77
+ "@scripts/build": "2.7.0"
78
78
  },
79
79
  "sideEffects": false,
80
80
  "publishConfig": {