@modern-js/router-v5-generator 3.5.0 → 3.6.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/index.js +23 -23
- package/package.json +10 -10
package/dist/index.js
CHANGED
|
@@ -51056,12 +51056,12 @@ __export(src_exports, {
|
|
|
51056
51056
|
module.exports = __toCommonJS(src_exports);
|
|
51057
51057
|
var import_path7 = __toESM(require("path"));
|
|
51058
51058
|
|
|
51059
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith@2.4.
|
|
51059
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith/dist/esm-node/materials/FsResource.js
|
|
51060
51060
|
var import_path = __toESM(require("path"));
|
|
51061
51061
|
var import_utils = require("@modern-js/utils");
|
|
51062
51062
|
var FS_RESOURCE = "_codesmith_core_fs_resource";
|
|
51063
51063
|
|
|
51064
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith@2.4.
|
|
51064
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith/dist/esm-node/utils/fsExists.js
|
|
51065
51065
|
var import_utils2 = require("@modern-js/utils");
|
|
51066
51066
|
async function fsExists(path7) {
|
|
51067
51067
|
try {
|
|
@@ -51072,13 +51072,13 @@ async function fsExists(path7) {
|
|
|
51072
51072
|
}
|
|
51073
51073
|
}
|
|
51074
51074
|
|
|
51075
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.4.
|
|
51075
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/utils/renderString.js
|
|
51076
51076
|
var import_ejs = __toESM(require_ejs());
|
|
51077
51077
|
function renderString(template, fullData) {
|
|
51078
51078
|
return import_ejs.default.render(template, fullData) || "";
|
|
51079
51079
|
}
|
|
51080
51080
|
|
|
51081
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.4.
|
|
51081
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-ejs@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-ejs/dist/esm-node/index.js
|
|
51082
51082
|
var EjsAPI = class {
|
|
51083
51083
|
async renderTemplate(templateResource, target, parameters = {}) {
|
|
51084
51084
|
if (templateResource._type !== FS_RESOURCE) {
|
|
@@ -51110,7 +51110,7 @@ var EjsAPI = class {
|
|
|
51110
51110
|
}
|
|
51111
51111
|
};
|
|
51112
51112
|
|
|
51113
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-fs@2.4.
|
|
51113
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-fs@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-fs/dist/esm-node/index.js
|
|
51114
51114
|
var import_path2 = __toESM(require("path"));
|
|
51115
51115
|
var import_utils4 = require("@modern-js/utils");
|
|
51116
51116
|
var FsAPI = class {
|
|
@@ -51137,7 +51137,7 @@ var FsAPI = class {
|
|
|
51137
51137
|
}
|
|
51138
51138
|
};
|
|
51139
51139
|
|
|
51140
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.4.
|
|
51140
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-git/dist/esm-node/utils/index.js
|
|
51141
51141
|
var import_utils5 = require("@modern-js/utils");
|
|
51142
51142
|
async function canUseGit() {
|
|
51143
51143
|
try {
|
|
@@ -51212,7 +51212,7 @@ async function gitCommit(cwd, commitMessage) {
|
|
|
51212
51212
|
});
|
|
51213
51213
|
}
|
|
51214
51214
|
|
|
51215
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.4.
|
|
51215
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-git@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-git/dist/esm-node/index.js
|
|
51216
51216
|
var GitAPI = class {
|
|
51217
51217
|
async isInGitRepo(cwd = this.generatorCore.outputPath) {
|
|
51218
51218
|
const canUse = await canUseGit();
|
|
@@ -51262,7 +51262,7 @@ var GitAPI = class {
|
|
|
51262
51262
|
}
|
|
51263
51263
|
};
|
|
51264
51264
|
|
|
51265
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.4.
|
|
51265
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/utils/renderString.js
|
|
51266
51266
|
var import_handlebars = __toESM(require_lib());
|
|
51267
51267
|
function renderString2(template, fullData, registers) {
|
|
51268
51268
|
const helpers = {
|
|
@@ -51276,7 +51276,7 @@ function renderString2(template, fullData, registers) {
|
|
|
51276
51276
|
return import_handlebars.default.compile(template)(fullData) || "";
|
|
51277
51277
|
}
|
|
51278
51278
|
|
|
51279
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.4.
|
|
51279
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-handlebars@2.4.2_@modern-js+codesmith@2.4.2/node_modules/@modern-js/codesmith-api-handlebars/dist/esm-node/index.js
|
|
51280
51280
|
var HandlebarsAPI = class {
|
|
51281
51281
|
async registerHelp(helpers) {
|
|
51282
51282
|
this.registers.helpers = {
|
|
@@ -51324,7 +51324,7 @@ var HandlebarsAPI = class {
|
|
|
51324
51324
|
}
|
|
51325
51325
|
};
|
|
51326
51326
|
|
|
51327
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.
|
|
51327
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.2/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/env.js
|
|
51328
51328
|
var import_utils8 = require("@modern-js/utils");
|
|
51329
51329
|
async function canUseNvm() {
|
|
51330
51330
|
try {
|
|
@@ -51374,7 +51374,7 @@ async function canUsePnpm() {
|
|
|
51374
51374
|
}
|
|
51375
51375
|
}
|
|
51376
51376
|
|
|
51377
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.
|
|
51377
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.2/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/utils/install.js
|
|
51378
51378
|
var import_utils9 = require("@modern-js/utils");
|
|
51379
51379
|
function execaWithStreamLog(command, args, options) {
|
|
51380
51380
|
const promise = (0, import_utils9.execa)(command, args, {
|
|
@@ -51470,7 +51470,7 @@ async function pnpmInstall({ cwd, registryUrl, ignoreScripts, useNvm }) {
|
|
|
51470
51470
|
throw new Error("please install pnpm first");
|
|
51471
51471
|
}
|
|
51472
51472
|
|
|
51473
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.
|
|
51473
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-npm@2.4.2/node_modules/@modern-js/codesmith-api-npm/dist/esm-node/index.js
|
|
51474
51474
|
var NpmAPI = class {
|
|
51475
51475
|
npmInstall({ cwd, registryUrl, ignoreScripts }) {
|
|
51476
51476
|
return npmInstall({
|
|
@@ -61054,10 +61054,10 @@ var Schema = (
|
|
|
61054
61054
|
}()
|
|
61055
61055
|
);
|
|
61056
61056
|
|
|
61057
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.
|
|
61057
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
|
|
61058
61058
|
var import_inquirer = __toESM(require_inquirer());
|
|
61059
61059
|
|
|
61060
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.
|
|
61060
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/transform.js
|
|
61061
61061
|
var import_lodash = require("@modern-js/utils/lodash");
|
|
61062
61062
|
function validateSchema(schema) {
|
|
61063
61063
|
const { type, properties } = schema;
|
|
@@ -61149,7 +61149,7 @@ function transformForm(schema, configValue = {}, validateMap, initValue) {
|
|
|
61149
61149
|
return getQuestionFromSchema(schema, configValue, validateMap, initValue);
|
|
61150
61150
|
}
|
|
61151
61151
|
|
|
61152
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.
|
|
61152
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/prompt.js
|
|
61153
61153
|
var compileRule = (rule, scope) => {
|
|
61154
61154
|
const state = Schema.compile(rule, {
|
|
61155
61155
|
$self: {},
|
|
@@ -61253,7 +61253,7 @@ async function prompt(schema, configValue = {}, validateMap, initValue) {
|
|
|
61253
61253
|
return answers;
|
|
61254
61254
|
}
|
|
61255
61255
|
|
|
61256
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.
|
|
61256
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-formily/dist/esm-node/inquirer.js
|
|
61257
61257
|
var CLIReader = class {
|
|
61258
61258
|
getAnswers() {
|
|
61259
61259
|
return this.answers;
|
|
@@ -61282,7 +61282,7 @@ var CLIReader = class {
|
|
|
61282
61282
|
}
|
|
61283
61283
|
};
|
|
61284
61284
|
|
|
61285
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61285
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
|
|
61286
61286
|
var import_utils13 = require("@modern-js/utils");
|
|
61287
61287
|
var import_lodash5 = require("@modern-js/utils/lodash");
|
|
61288
61288
|
var import_comment_json = __toESM(require_src2());
|
|
@@ -61351,7 +61351,7 @@ var I18n = class {
|
|
|
61351
61351
|
}
|
|
61352
61352
|
};
|
|
61353
61353
|
|
|
61354
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61354
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/en.js
|
|
61355
61355
|
var EN_LOCALE = {
|
|
61356
61356
|
environment: {
|
|
61357
61357
|
node_version: "please upgrade node to lts version",
|
|
@@ -61378,7 +61378,7 @@ var EN_LOCALE = {
|
|
|
61378
61378
|
}
|
|
61379
61379
|
};
|
|
61380
61380
|
|
|
61381
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61381
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/zh.js
|
|
61382
61382
|
var ZH_LOCALE = {
|
|
61383
61383
|
environment: {
|
|
61384
61384
|
node_version: "请升级 Node 版本至 LIS",
|
|
@@ -61405,14 +61405,14 @@ var ZH_LOCALE = {
|
|
|
61405
61405
|
}
|
|
61406
61406
|
};
|
|
61407
61407
|
|
|
61408
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61408
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/locale/index.js
|
|
61409
61409
|
var i18n = new I18n();
|
|
61410
61410
|
var localeKeys = i18n.init("zh", {
|
|
61411
61411
|
zh: ZH_LOCALE,
|
|
61412
61412
|
en: EN_LOCALE
|
|
61413
61413
|
});
|
|
61414
61414
|
|
|
61415
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61415
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/checkUseNvm.js
|
|
61416
61416
|
var import_path4 = __toESM(require("path"));
|
|
61417
61417
|
var import_utils12 = require("@modern-js/utils");
|
|
61418
61418
|
var NODE_MAJOR_VERSION_MAP = {
|
|
@@ -61460,7 +61460,7 @@ async function checkUseNvm(cwd, logger) {
|
|
|
61460
61460
|
}
|
|
61461
61461
|
}
|
|
61462
61462
|
|
|
61463
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61463
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/utils/transform.js
|
|
61464
61464
|
var import_lodash4 = require("@modern-js/utils/lodash");
|
|
61465
61465
|
function transformInquirerSchema(questions, configValue = {}, validateMap = {}, initValue = {}) {
|
|
61466
61466
|
for (const question of questions) {
|
|
@@ -61488,7 +61488,7 @@ function transformInquirerSchema(questions, configValue = {}, validateMap = {},
|
|
|
61488
61488
|
return questions;
|
|
61489
61489
|
}
|
|
61490
61490
|
|
|
61491
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.
|
|
61491
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.4.2_@modern-js+codesmith@2.4.2_typescript@5.3.3/node_modules/@modern-js/codesmith-api-app/dist/esm-node/index.js
|
|
61492
61492
|
var AppAPI = class {
|
|
61493
61493
|
async checkEnvironment(nodeVersion) {
|
|
61494
61494
|
if (import_utils13.semver.lt(process.versions.node, nodeVersion || "12.22.12")) {
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"modern",
|
|
16
16
|
"modern.js"
|
|
17
17
|
],
|
|
18
|
-
"version": "3.
|
|
18
|
+
"version": "3.6.0",
|
|
19
19
|
"jsnext:source": "./src/index.ts",
|
|
20
20
|
"main": "./dist/index.js",
|
|
21
21
|
"files": [
|
|
@@ -23,21 +23,21 @@
|
|
|
23
23
|
"/dist/index.js"
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@modern-js/utils": "2.
|
|
26
|
+
"@modern-js/utils": "2.60.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@modern-js/codesmith": "2.4.
|
|
30
|
-
"@modern-js/codesmith-api-app": "2.4.
|
|
29
|
+
"@modern-js/codesmith": "2.4.2",
|
|
30
|
+
"@modern-js/codesmith-api-app": "2.4.2",
|
|
31
31
|
"@types/jest": "^29",
|
|
32
32
|
"@types/node": "^14",
|
|
33
33
|
"jest": "^29",
|
|
34
34
|
"typescript": "^5",
|
|
35
|
-
"@modern-js/dependence-generator": "3.
|
|
36
|
-
"@modern-js/generator-utils": "3.
|
|
37
|
-
"@modern-js/
|
|
38
|
-
"@
|
|
39
|
-
"@
|
|
40
|
-
"@scripts/
|
|
35
|
+
"@modern-js/dependence-generator": "3.6.0",
|
|
36
|
+
"@modern-js/generator-utils": "3.6.0",
|
|
37
|
+
"@modern-js/plugin-i18n": "2.60.0",
|
|
38
|
+
"@scripts/build": "2.60.0",
|
|
39
|
+
"@modern-js/generator-common": "3.6.0",
|
|
40
|
+
"@scripts/jest-config": "2.60.0"
|
|
41
41
|
},
|
|
42
42
|
"sideEffects": false,
|
|
43
43
|
"publishConfig": {
|