@modern-js/plugin-bff 2.5.1-alpha.2 → 2.5.1-alpha.3
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/dist/cjs/cli.js +3 -3
- package/dist/esm/cli.js +4 -4
- package/dist/esm-node/cli.js +3 -3
- package/package.json +2 -2
package/dist/cjs/cli.js
CHANGED
|
@@ -124,11 +124,11 @@ var cli_default = () => ({
|
|
|
124
124
|
if (unRegisterResolveRuntimePath) {
|
|
125
125
|
unRegisterResolveRuntimePath();
|
|
126
126
|
}
|
|
127
|
-
const { appDirectory, distDirectory } = api.useAppContext();
|
|
127
|
+
const { appDirectory, distDirectory, apiDirectory, sharedDirectory } = api.useAppContext();
|
|
128
128
|
const modernConfig = api.useResolvedConfigContext();
|
|
129
129
|
const distDir = import_path.default.resolve(distDirectory);
|
|
130
|
-
const apiDir = import_path.default.resolve(appDirectory, import_utils.API_DIR);
|
|
131
|
-
const sharedDir = import_path.default.resolve(appDirectory, import_utils.SHARED_DIR);
|
|
130
|
+
const apiDir = apiDirectory || import_path.default.resolve(appDirectory, import_utils.API_DIR);
|
|
131
|
+
const sharedDir = sharedDirectory || import_path.default.resolve(appDirectory, import_utils.SHARED_DIR);
|
|
132
132
|
const tsconfigPath = import_path.default.resolve(appDirectory, TS_CONFIG_FILENAME);
|
|
133
133
|
const sourceDirs = [];
|
|
134
134
|
if (import_utils.fs.existsSync(apiDir)) {
|
package/dist/esm/cli.js
CHANGED
|
@@ -314,18 +314,18 @@ var cli_default = function() {
|
|
|
314
314
|
},
|
|
315
315
|
afterBuild: function afterBuild() {
|
|
316
316
|
return _asyncToGenerator(function() {
|
|
317
|
-
var _api_useAppContext, appDirectory, distDirectory, modernConfig, distDir, apiDir, sharedDir, tsconfigPath, sourceDirs, server, _modernConfig_source, alias, define, globalVars, babel;
|
|
317
|
+
var _api_useAppContext, appDirectory, distDirectory, apiDirectory, sharedDirectory, modernConfig, distDir, apiDir, sharedDir, tsconfigPath, sourceDirs, server, _modernConfig_source, alias, define, globalVars, babel;
|
|
318
318
|
return __generator(this, function(_state) {
|
|
319
319
|
switch(_state.label){
|
|
320
320
|
case 0:
|
|
321
321
|
if (unRegisterResolveRuntimePath) {
|
|
322
322
|
unRegisterResolveRuntimePath();
|
|
323
323
|
}
|
|
324
|
-
_api_useAppContext = api.useAppContext(), appDirectory = _api_useAppContext.appDirectory, distDirectory = _api_useAppContext.distDirectory;
|
|
324
|
+
_api_useAppContext = api.useAppContext(), appDirectory = _api_useAppContext.appDirectory, distDirectory = _api_useAppContext.distDirectory, apiDirectory = _api_useAppContext.apiDirectory, sharedDirectory = _api_useAppContext.sharedDirectory;
|
|
325
325
|
modernConfig = api.useResolvedConfigContext();
|
|
326
326
|
distDir = path.resolve(distDirectory);
|
|
327
|
-
apiDir = path.resolve(appDirectory, API_DIR);
|
|
328
|
-
sharedDir = path.resolve(appDirectory, SHARED_DIR);
|
|
327
|
+
apiDir = apiDirectory || path.resolve(appDirectory, API_DIR);
|
|
328
|
+
sharedDir = sharedDirectory || path.resolve(appDirectory, SHARED_DIR);
|
|
329
329
|
tsconfigPath = path.resolve(appDirectory, TS_CONFIG_FILENAME);
|
|
330
330
|
sourceDirs = [];
|
|
331
331
|
if (fs.existsSync(apiDir)) {
|
package/dist/esm-node/cli.js
CHANGED
|
@@ -103,11 +103,11 @@ var cli_default = () => ({
|
|
|
103
103
|
if (unRegisterResolveRuntimePath) {
|
|
104
104
|
unRegisterResolveRuntimePath();
|
|
105
105
|
}
|
|
106
|
-
const { appDirectory, distDirectory } = api.useAppContext();
|
|
106
|
+
const { appDirectory, distDirectory, apiDirectory, sharedDirectory } = api.useAppContext();
|
|
107
107
|
const modernConfig = api.useResolvedConfigContext();
|
|
108
108
|
const distDir = path.resolve(distDirectory);
|
|
109
|
-
const apiDir = path.resolve(appDirectory, API_DIR);
|
|
110
|
-
const sharedDir = path.resolve(appDirectory, SHARED_DIR);
|
|
109
|
+
const apiDir = apiDirectory || path.resolve(appDirectory, API_DIR);
|
|
110
|
+
const sharedDir = sharedDirectory || path.resolve(appDirectory, SHARED_DIR);
|
|
111
111
|
const tsconfigPath = path.resolve(appDirectory, TS_CONFIG_FILENAME);
|
|
112
112
|
const sourceDirs = [];
|
|
113
113
|
if (fs.existsSync(apiDir)) {
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"modern",
|
|
12
12
|
"modern.js"
|
|
13
13
|
],
|
|
14
|
-
"version": "2.5.1-alpha.
|
|
14
|
+
"version": "2.5.1-alpha.3",
|
|
15
15
|
"jsnext:source": "./src/cli.ts",
|
|
16
16
|
"types": "./dist/types/cli.d.ts",
|
|
17
17
|
"main": "./dist/cjs/cli.js",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"@babel/runtime": "^7.18.0",
|
|
53
53
|
"@modern-js/bff-core": "2.5.1-alpha.1",
|
|
54
54
|
"@modern-js/create-request": "2.5.1-alpha.5",
|
|
55
|
-
"@modern-js/server-utils": "2.5.0",
|
|
55
|
+
"@modern-js/server-utils": "2.5.1-alpha.0",
|
|
56
56
|
"@modern-js/utils": "2.5.0"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|