@modern-js/plugin-bff 3.0.4 → 3.1.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/dist/cjs/loader.js
CHANGED
|
@@ -34,7 +34,7 @@ async function loader(source) {
|
|
|
34
34
|
delete require.cache[resourcePath];
|
|
35
35
|
const callback = this.async();
|
|
36
36
|
const draftOptions = this.getOptions();
|
|
37
|
-
const warning = `The file ${resourcePath} is not
|
|
37
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
38
38
|
if (!draftOptions.existLambda) {
|
|
39
39
|
utils_namespaceObject.logger.warn(warning);
|
|
40
40
|
callback(null, `throw new Error('${warning}')`);
|
|
@@ -178,7 +178,7 @@ async function copyFiles(from, to) {
|
|
|
178
178
|
async function clientGenerator(draftOptions) {
|
|
179
179
|
const sourceList = await readDirectoryFiles(draftOptions.appDir, draftOptions.lambdaDir, draftOptions.relativeDistPath);
|
|
180
180
|
const getClitentCode = async (resourcePath, source)=>{
|
|
181
|
-
const warning = `The file ${resourcePath} is not
|
|
181
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
182
182
|
if (!draftOptions.existLambda) return void utils_namespaceObject.logger.warn(warning);
|
|
183
183
|
const options = {
|
|
184
184
|
prefix: Array.isArray(draftOptions.prefix) ? draftOptions.prefix[0] : draftOptions.prefix,
|
package/dist/esm/loader.mjs
CHANGED
|
@@ -6,7 +6,7 @@ async function loader(source) {
|
|
|
6
6
|
delete require.cache[resourcePath];
|
|
7
7
|
const callback = this.async();
|
|
8
8
|
const draftOptions = this.getOptions();
|
|
9
|
-
const warning = `The file ${resourcePath} is not
|
|
9
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
10
10
|
if (!draftOptions.existLambda) {
|
|
11
11
|
logger.warn(warning);
|
|
12
12
|
callback(null, `throw new Error('${warning}')`);
|
|
@@ -138,7 +138,7 @@ async function copyFiles(from, to) {
|
|
|
138
138
|
async function clientGenerator(draftOptions) {
|
|
139
139
|
const sourceList = await readDirectoryFiles(draftOptions.appDir, draftOptions.lambdaDir, draftOptions.relativeDistPath);
|
|
140
140
|
const getClitentCode = async (resourcePath, source)=>{
|
|
141
|
-
const warning = `The file ${resourcePath} is not
|
|
141
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
142
142
|
if (!draftOptions.existLambda) return void logger.warn(warning);
|
|
143
143
|
const options = {
|
|
144
144
|
prefix: Array.isArray(draftOptions.prefix) ? draftOptions.prefix[0] : draftOptions.prefix,
|
package/dist/esm-node/loader.mjs
CHANGED
|
@@ -8,7 +8,7 @@ async function loader(source) {
|
|
|
8
8
|
delete require.cache[resourcePath];
|
|
9
9
|
const callback = this.async();
|
|
10
10
|
const draftOptions = this.getOptions();
|
|
11
|
-
const warning = `The file ${resourcePath} is not
|
|
11
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
12
12
|
if (!draftOptions.existLambda) {
|
|
13
13
|
logger.warn(warning);
|
|
14
14
|
callback(null, `throw new Error('${warning}')`);
|
|
@@ -139,7 +139,7 @@ async function copyFiles(from, to) {
|
|
|
139
139
|
async function clientGenerator(draftOptions) {
|
|
140
140
|
const sourceList = await readDirectoryFiles(draftOptions.appDir, draftOptions.lambdaDir, draftOptions.relativeDistPath);
|
|
141
141
|
const getClitentCode = async (resourcePath, source)=>{
|
|
142
|
-
const warning = `The file ${resourcePath} is not
|
|
142
|
+
const warning = `The file ${resourcePath} is not allowed to be imported in src directory, only API definition files are allowed.`;
|
|
143
143
|
if (!draftOptions.existLambda) return void logger.warn(warning);
|
|
144
144
|
const options = {
|
|
145
145
|
prefix: Array.isArray(draftOptions.prefix) ? draftOptions.prefix[0] : draftOptions.prefix,
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"modern",
|
|
16
16
|
"modern.js"
|
|
17
17
|
],
|
|
18
|
-
"version": "3.0
|
|
18
|
+
"version": "3.1.0",
|
|
19
19
|
"types": "./dist/types/cli.d.ts",
|
|
20
20
|
"main": "./dist/cjs/cli.js",
|
|
21
21
|
"exports": {
|
|
@@ -79,28 +79,28 @@
|
|
|
79
79
|
"@swc/helpers": "^0.5.17",
|
|
80
80
|
"qs": "^6.15.0",
|
|
81
81
|
"type-is": "^1.6.18",
|
|
82
|
-
"@modern-js/bff-core": "3.0
|
|
83
|
-
"@modern-js/builder": "3.0
|
|
84
|
-
"@modern-js/create-request": "3.0
|
|
85
|
-
"@modern-js/server-core": "3.0
|
|
86
|
-
"@modern-js/server-utils": "3.0
|
|
87
|
-
"@modern-js/utils": "3.0
|
|
82
|
+
"@modern-js/bff-core": "3.1.0",
|
|
83
|
+
"@modern-js/builder": "3.1.0",
|
|
84
|
+
"@modern-js/create-request": "3.1.0",
|
|
85
|
+
"@modern-js/server-core": "3.1.0",
|
|
86
|
+
"@modern-js/server-utils": "3.1.0",
|
|
87
|
+
"@modern-js/utils": "3.1.0"
|
|
88
88
|
},
|
|
89
89
|
"devDependencies": {
|
|
90
90
|
"@rsbuild/core": "2.0.0-beta.4",
|
|
91
91
|
"@rslib/core": "0.19.6",
|
|
92
92
|
"@types/node": "^20",
|
|
93
|
-
"@types/qs": "^6.
|
|
93
|
+
"@types/qs": "^6.15.0",
|
|
94
94
|
"@types/type-is": "^1.6.7",
|
|
95
95
|
"memfs": "^3.5.3",
|
|
96
96
|
"typescript": "^5",
|
|
97
97
|
"zod": "^3.25.76",
|
|
98
|
-
"@modern-js/app-tools": "3.0
|
|
99
|
-
"@modern-js/bff-runtime": "3.0
|
|
100
|
-
"@modern-js/plugin": "3.0
|
|
98
|
+
"@modern-js/app-tools": "3.1.0",
|
|
99
|
+
"@modern-js/bff-runtime": "3.1.0",
|
|
100
|
+
"@modern-js/plugin": "3.1.0",
|
|
101
101
|
"@modern-js/rslib": "2.68.10",
|
|
102
|
-
"@modern-js/runtime": "3.0
|
|
103
|
-
"@modern-js/types": "3.0
|
|
102
|
+
"@modern-js/runtime": "3.1.0",
|
|
103
|
+
"@modern-js/types": "3.1.0",
|
|
104
104
|
"@scripts/rstest-config": "2.66.0"
|
|
105
105
|
},
|
|
106
106
|
"sideEffects": false,
|