@modern-js/base-generator 3.1.20 → 3.1.22
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 +32 -287
- package/package.json +7 -6
package/dist/index.js
CHANGED
|
@@ -42252,7 +42252,7 @@ var require_parse = __commonJS({
|
|
|
42252
42252
|
return current.type === "Punctuator" ? current.value : current.type;
|
|
42253
42253
|
};
|
|
42254
42254
|
var is = (t) => type() === t;
|
|
42255
|
-
var
|
|
42255
|
+
var expect = (a) => {
|
|
42256
42256
|
if (!is(a)) {
|
|
42257
42257
|
unexpected();
|
|
42258
42258
|
}
|
|
@@ -42334,7 +42334,7 @@ var require_parse = __commonJS({
|
|
|
42334
42334
|
while (!is(CURLY_BRACKET_CLOSE)) {
|
|
42335
42335
|
if (started) {
|
|
42336
42336
|
assign_comments(PREFIX_AFTER_VALUE);
|
|
42337
|
-
|
|
42337
|
+
expect(COMMA);
|
|
42338
42338
|
next();
|
|
42339
42339
|
parse_comments();
|
|
42340
42340
|
assign_after_comments();
|
|
@@ -42343,13 +42343,13 @@ var require_parse = __commonJS({
|
|
|
42343
42343
|
}
|
|
42344
42344
|
}
|
|
42345
42345
|
started = true;
|
|
42346
|
-
|
|
42346
|
+
expect("String");
|
|
42347
42347
|
name = JSON.parse(current.value);
|
|
42348
42348
|
set_prop(name);
|
|
42349
42349
|
assign_comments(PREFIX_BEFORE);
|
|
42350
42350
|
next();
|
|
42351
42351
|
parse_comments(PREFIX_AFTER_PROP);
|
|
42352
|
-
|
|
42352
|
+
expect(COLON);
|
|
42353
42353
|
next();
|
|
42354
42354
|
parse_comments(PREFIX_AFTER_COLON);
|
|
42355
42355
|
obj[name] = transform(name, walk());
|
|
@@ -42377,7 +42377,7 @@ var require_parse = __commonJS({
|
|
|
42377
42377
|
while (!is(BRACKET_CLOSE)) {
|
|
42378
42378
|
if (started) {
|
|
42379
42379
|
assign_comments(PREFIX_AFTER_VALUE);
|
|
42380
|
-
|
|
42380
|
+
expect(COMMA);
|
|
42381
42381
|
next();
|
|
42382
42382
|
parse_comments();
|
|
42383
42383
|
assign_after_comments();
|
|
@@ -113897,6 +113897,9 @@ var require_constants = __commonJS({
|
|
|
113897
113897
|
ROUTE_SPEC_FILE: function() {
|
|
113898
113898
|
return ROUTE_SPEC_FILE;
|
|
113899
113899
|
},
|
|
113900
|
+
NESTED_ROUTE_SPEC_FILE: function() {
|
|
113901
|
+
return NESTED_ROUTE_SPEC_FILE;
|
|
113902
|
+
},
|
|
113900
113903
|
MAIN_ENTRY_NAME: function() {
|
|
113901
113904
|
return MAIN_ENTRY_NAME;
|
|
113902
113905
|
},
|
|
@@ -113981,9 +113984,6 @@ var require_constants = __commonJS({
|
|
|
113981
113984
|
INTERNAL_SERVER_PLUGINS: function() {
|
|
113982
113985
|
return INTERNAL_SERVER_PLUGINS;
|
|
113983
113986
|
},
|
|
113984
|
-
PLUGIN_SCHEMAS: function() {
|
|
113985
|
-
return PLUGIN_SCHEMAS;
|
|
113986
|
-
},
|
|
113987
113987
|
DEFAULT_BABEL_PRESET_TYPESCRIPT_OPTIONS: function() {
|
|
113988
113988
|
return DEFAULT_BABEL_PRESET_TYPESCRIPT_OPTIONS;
|
|
113989
113989
|
}
|
|
@@ -113991,6 +113991,7 @@ var require_constants = __commonJS({
|
|
|
113991
113991
|
var _export_star = require_export_star();
|
|
113992
113992
|
_export_star._(require_chainId(), exports);
|
|
113993
113993
|
var ROUTE_SPEC_FILE = "route.json";
|
|
113994
|
+
var NESTED_ROUTE_SPEC_FILE = "nestedRoutes.json";
|
|
113994
113995
|
var MAIN_ENTRY_NAME = "main";
|
|
113995
113996
|
var SERVER_BUNDLE_DIRECTORY = "bundles";
|
|
113996
113997
|
var SERVER_WORKER_BUNDLE_DIRECTORY = "worker";
|
|
@@ -114037,8 +114038,6 @@ var require_constants = __commonJS({
|
|
|
114037
114038
|
"@modern-js/plugin-testing": "@modern-js/plugin-testing/cli",
|
|
114038
114039
|
"@modern-js/plugin-storybook": "@modern-js/plugin-storybook/cli",
|
|
114039
114040
|
"@modern-js/plugin-tailwindcss": "@modern-js/plugin-tailwindcss/cli",
|
|
114040
|
-
// TODO: Maybe can remove it
|
|
114041
|
-
"@modern-js/plugin-nocode": "@modern-js/plugin-nocode/cli",
|
|
114042
114041
|
// legacy router (inner react-router-dom v5)
|
|
114043
114042
|
"@modern-js/plugin-router-legacy": "@modern-js/plugin-router-legacy/cli"
|
|
114044
114043
|
};
|
|
@@ -114069,8 +114068,6 @@ var require_constants = __commonJS({
|
|
|
114069
114068
|
"@modern-js/plugin-garfish": "@modern-js/plugin-garfish/cli",
|
|
114070
114069
|
"@modern-js/plugin-tailwindcss": "@modern-js/plugin-tailwindcss/cli",
|
|
114071
114070
|
"@modern-js/plugin-polyfill": "@modern-js/plugin-polyfill/cli",
|
|
114072
|
-
// TODO: Maybe can remove it
|
|
114073
|
-
"@modern-js/plugin-nocode": "@modern-js/plugin-nocode/cli",
|
|
114074
114071
|
// legacy router (inner react-router-dom v5)
|
|
114075
114072
|
"@modern-js/plugin-router-v5": "@modern-js/plugin-router-v5/cli"
|
|
114076
114073
|
};
|
|
@@ -114086,214 +114083,6 @@ var require_constants = __commonJS({
|
|
|
114086
114083
|
[SERVER_PLUGIN_SERVER]: "@modern-js/plugin-server/server",
|
|
114087
114084
|
[SERVER_PLUGIN_POLYFILL]: "@modern-js/plugin-polyfill/server"
|
|
114088
114085
|
};
|
|
114089
|
-
var PLUGIN_SCHEMAS = {
|
|
114090
|
-
"@modern-js/runtime": [
|
|
114091
|
-
{
|
|
114092
|
-
target: "runtime",
|
|
114093
|
-
schema: {
|
|
114094
|
-
type: "object",
|
|
114095
|
-
additionalProperties: false
|
|
114096
|
-
}
|
|
114097
|
-
},
|
|
114098
|
-
{
|
|
114099
|
-
target: "runtimeByEntries",
|
|
114100
|
-
schema: {
|
|
114101
|
-
type: "object",
|
|
114102
|
-
patternProperties: {
|
|
114103
|
-
[ENTRY_NAME_PATTERN]: {
|
|
114104
|
-
type: "object"
|
|
114105
|
-
}
|
|
114106
|
-
},
|
|
114107
|
-
additionalProperties: false
|
|
114108
|
-
}
|
|
114109
|
-
}
|
|
114110
|
-
],
|
|
114111
|
-
"@modern-js/plugin-swc": [
|
|
114112
|
-
{
|
|
114113
|
-
target: "tools.swc",
|
|
114114
|
-
schema: {
|
|
114115
|
-
typeof: [
|
|
114116
|
-
"object"
|
|
114117
|
-
]
|
|
114118
|
-
}
|
|
114119
|
-
}
|
|
114120
|
-
],
|
|
114121
|
-
"@modern-js/plugin-bff": [
|
|
114122
|
-
{
|
|
114123
|
-
target: "bff",
|
|
114124
|
-
schema: {
|
|
114125
|
-
type: "object",
|
|
114126
|
-
properties: {
|
|
114127
|
-
prefix: {
|
|
114128
|
-
type: [
|
|
114129
|
-
"string",
|
|
114130
|
-
"array"
|
|
114131
|
-
],
|
|
114132
|
-
items: {
|
|
114133
|
-
type: "string"
|
|
114134
|
-
}
|
|
114135
|
-
},
|
|
114136
|
-
fetcher: {
|
|
114137
|
-
type: "string"
|
|
114138
|
-
},
|
|
114139
|
-
proxy: {
|
|
114140
|
-
type: "object"
|
|
114141
|
-
},
|
|
114142
|
-
requestCreator: {
|
|
114143
|
-
type: "string"
|
|
114144
|
-
}
|
|
114145
|
-
}
|
|
114146
|
-
}
|
|
114147
|
-
}
|
|
114148
|
-
],
|
|
114149
|
-
"@modern-js/plugin-tailwindcss": [
|
|
114150
|
-
{
|
|
114151
|
-
target: "tools.tailwindcss",
|
|
114152
|
-
schema: {
|
|
114153
|
-
typeof: [
|
|
114154
|
-
"object",
|
|
114155
|
-
"function"
|
|
114156
|
-
]
|
|
114157
|
-
}
|
|
114158
|
-
}
|
|
114159
|
-
],
|
|
114160
|
-
"@modern-js/plugin-proxy": [
|
|
114161
|
-
{
|
|
114162
|
-
target: "dev.proxy",
|
|
114163
|
-
schema: {
|
|
114164
|
-
typeof: [
|
|
114165
|
-
"string",
|
|
114166
|
-
"object"
|
|
114167
|
-
]
|
|
114168
|
-
}
|
|
114169
|
-
}
|
|
114170
|
-
],
|
|
114171
|
-
"@modern-js/plugin-ssg": [
|
|
114172
|
-
{
|
|
114173
|
-
target: "output.ssg",
|
|
114174
|
-
schema: {
|
|
114175
|
-
oneOf: [
|
|
114176
|
-
{
|
|
114177
|
-
type: "boolean"
|
|
114178
|
-
},
|
|
114179
|
-
{
|
|
114180
|
-
type: "object"
|
|
114181
|
-
},
|
|
114182
|
-
{
|
|
114183
|
-
instanceof: "Function"
|
|
114184
|
-
}
|
|
114185
|
-
]
|
|
114186
|
-
}
|
|
114187
|
-
}
|
|
114188
|
-
],
|
|
114189
|
-
"@modern-js/plugin-state": [
|
|
114190
|
-
{
|
|
114191
|
-
target: "runtime.state",
|
|
114192
|
-
schema: {
|
|
114193
|
-
type: [
|
|
114194
|
-
"boolean",
|
|
114195
|
-
"object"
|
|
114196
|
-
]
|
|
114197
|
-
}
|
|
114198
|
-
}
|
|
114199
|
-
],
|
|
114200
|
-
"@modern-js/plugin-design-token": [
|
|
114201
|
-
// Legacy Features
|
|
114202
|
-
{
|
|
114203
|
-
target: "source.designSystem",
|
|
114204
|
-
schema: {
|
|
114205
|
-
typeof: [
|
|
114206
|
-
"object"
|
|
114207
|
-
]
|
|
114208
|
-
}
|
|
114209
|
-
},
|
|
114210
|
-
{
|
|
114211
|
-
target: "source.designSystem.supportStyledComponents",
|
|
114212
|
-
schema: {
|
|
114213
|
-
type: [
|
|
114214
|
-
"boolean"
|
|
114215
|
-
]
|
|
114216
|
-
}
|
|
114217
|
-
},
|
|
114218
|
-
{
|
|
114219
|
-
target: "designSystem",
|
|
114220
|
-
schema: {
|
|
114221
|
-
typeof: [
|
|
114222
|
-
"object"
|
|
114223
|
-
]
|
|
114224
|
-
}
|
|
114225
|
-
}
|
|
114226
|
-
],
|
|
114227
|
-
"@modern-js/plugin-router": [
|
|
114228
|
-
{
|
|
114229
|
-
target: "runtime.router",
|
|
114230
|
-
schema: {
|
|
114231
|
-
type: [
|
|
114232
|
-
"boolean",
|
|
114233
|
-
"object"
|
|
114234
|
-
]
|
|
114235
|
-
}
|
|
114236
|
-
}
|
|
114237
|
-
],
|
|
114238
|
-
"@modern-js/plugin-testing": [
|
|
114239
|
-
{
|
|
114240
|
-
target: "testing",
|
|
114241
|
-
schema: {
|
|
114242
|
-
typeof: [
|
|
114243
|
-
"object"
|
|
114244
|
-
]
|
|
114245
|
-
}
|
|
114246
|
-
},
|
|
114247
|
-
{
|
|
114248
|
-
target: "tools.jest",
|
|
114249
|
-
schema: {
|
|
114250
|
-
typeof: [
|
|
114251
|
-
"object",
|
|
114252
|
-
"function"
|
|
114253
|
-
]
|
|
114254
|
-
}
|
|
114255
|
-
}
|
|
114256
|
-
],
|
|
114257
|
-
"@modern-js/plugin-garfish": [
|
|
114258
|
-
{
|
|
114259
|
-
target: "runtime.masterApp",
|
|
114260
|
-
schema: {
|
|
114261
|
-
type: [
|
|
114262
|
-
"boolean",
|
|
114263
|
-
"object"
|
|
114264
|
-
]
|
|
114265
|
-
}
|
|
114266
|
-
},
|
|
114267
|
-
{
|
|
114268
|
-
target: "dev.withMasterApp",
|
|
114269
|
-
schema: {
|
|
114270
|
-
type: [
|
|
114271
|
-
"object"
|
|
114272
|
-
]
|
|
114273
|
-
}
|
|
114274
|
-
},
|
|
114275
|
-
{
|
|
114276
|
-
target: "deploy.microFrontend",
|
|
114277
|
-
schema: {
|
|
114278
|
-
type: [
|
|
114279
|
-
"boolean",
|
|
114280
|
-
"object"
|
|
114281
|
-
]
|
|
114282
|
-
}
|
|
114283
|
-
}
|
|
114284
|
-
],
|
|
114285
|
-
"@modern-js/plugin-nocode": [],
|
|
114286
|
-
"@modern-js/plugin-worker": [
|
|
114287
|
-
{
|
|
114288
|
-
target: "deploy.worker.ssr",
|
|
114289
|
-
schema: {
|
|
114290
|
-
type: [
|
|
114291
|
-
"boolean"
|
|
114292
|
-
]
|
|
114293
|
-
}
|
|
114294
|
-
}
|
|
114295
|
-
]
|
|
114296
|
-
};
|
|
114297
114086
|
var DEFAULT_BABEL_PRESET_TYPESCRIPT_OPTIONS = {
|
|
114298
114087
|
allowNamespaces: true,
|
|
114299
114088
|
allExtensions: true,
|
|
@@ -114748,11 +114537,14 @@ var require_project = __commonJS({
|
|
|
114748
114537
|
return false;
|
|
114749
114538
|
}
|
|
114750
114539
|
};
|
|
114751
|
-
var isApiOnly = (appDirectory, entryDir) => __async(exports, null, function* () {
|
|
114752
|
-
const
|
|
114753
|
-
const existSrc = yield _compiled.fs.pathExists(
|
|
114540
|
+
var isApiOnly = (appDirectory, entryDir, apiDir) => __async(exports, null, function* () {
|
|
114541
|
+
const existApi = yield _compiled.fs.pathExists(apiDir !== null && apiDir !== void 0 ? apiDir : _path.default.join(appDirectory, "api"));
|
|
114542
|
+
const existSrc = yield _compiled.fs.pathExists(_path.default.join(appDirectory, entryDir !== null && entryDir !== void 0 ? entryDir : "src"));
|
|
114754
114543
|
const options = (0, _compiled.minimist)((0, _commands.getArgv)());
|
|
114755
|
-
|
|
114544
|
+
if (options["api-only"]) {
|
|
114545
|
+
return true;
|
|
114546
|
+
}
|
|
114547
|
+
return existApi && !existSrc;
|
|
114756
114548
|
});
|
|
114757
114549
|
var isWebOnly = () => __async(exports, null, function* () {
|
|
114758
114550
|
const options = (0, _compiled.minimist)((0, _commands.getArgv)());
|
|
@@ -115086,21 +114878,6 @@ var require_get2 = __commonJS({
|
|
|
115086
114878
|
}
|
|
115087
114879
|
});
|
|
115088
114880
|
|
|
115089
|
-
// ../../../../node_modules/.pnpm/@swc+helpers@0.5.1/node_modules/@swc/helpers/cjs/_define_property.cjs
|
|
115090
|
-
var require_define_property = __commonJS({
|
|
115091
|
-
"../../../../node_modules/.pnpm/@swc+helpers@0.5.1/node_modules/@swc/helpers/cjs/_define_property.cjs"(exports) {
|
|
115092
|
-
"use strict";
|
|
115093
|
-
exports._ = exports._define_property = _define_property14;
|
|
115094
|
-
function _define_property14(obj, key, value) {
|
|
115095
|
-
if (key in obj) {
|
|
115096
|
-
Object.defineProperty(obj, key, { value, enumerable: true, configurable: true, writable: true });
|
|
115097
|
-
} else
|
|
115098
|
-
obj[key] = value;
|
|
115099
|
-
return obj;
|
|
115100
|
-
}
|
|
115101
|
-
}
|
|
115102
|
-
});
|
|
115103
|
-
|
|
115104
114881
|
// ../../../toolkit/utils/dist/cjs/cli/logger.js
|
|
115105
114882
|
var require_logger2 = __commonJS({
|
|
115106
114883
|
"../../../toolkit/utils/dist/cjs/cli/logger.js"(exports) {
|
|
@@ -115123,7 +114900,6 @@ var require_logger2 = __commonJS({
|
|
|
115123
114900
|
return logger;
|
|
115124
114901
|
}
|
|
115125
114902
|
});
|
|
115126
|
-
var _define_property14 = require_define_property();
|
|
115127
114903
|
var _interop_require_default = require_interop_require_default();
|
|
115128
114904
|
var _chalk = /* @__PURE__ */ _interop_require_default._(require_chalk2());
|
|
115129
114905
|
var LOG_LEVEL = {
|
|
@@ -115209,10 +114985,6 @@ ${_chalk.default.grey(rest.join("\n"))}`;
|
|
|
115209
114985
|
return longestLabel;
|
|
115210
114986
|
}
|
|
115211
114987
|
constructor(options = {}) {
|
|
115212
|
-
_define_property14._(this, "level", void 0);
|
|
115213
|
-
_define_property14._(this, "config", void 0);
|
|
115214
|
-
_define_property14._(this, "types", void 0);
|
|
115215
|
-
_define_property14._(this, "longestLabel", void 0);
|
|
115216
114988
|
this.level = options.level || LOG_TYPES.log.level;
|
|
115217
114989
|
this.config = __spreadValues(__spreadValues({}, DEFAULT_CONFIG), options.config || {});
|
|
115218
114990
|
this.types = __spreadValues(__spreadValues({}, LOG_TYPES), options.types || {});
|
|
@@ -115893,9 +115665,10 @@ var require_prettyInstructions = __commonJS({
|
|
|
115893
115665
|
}, []);
|
|
115894
115666
|
};
|
|
115895
115667
|
var prettyInstructions = (appContext, config) => {
|
|
115896
|
-
var _config_dev;
|
|
115668
|
+
var _appContext_builder_context_devServer, _appContext_builder, _config_dev;
|
|
115897
115669
|
const { entrypoints, serverRoutes, port, apiOnly, checkedEntries } = appContext;
|
|
115898
|
-
const
|
|
115670
|
+
const isHttps = (0, _is.isDev)() && ((_appContext_builder_context_devServer = (_appContext_builder = appContext.builder) === null || _appContext_builder === void 0 ? void 0 : _appContext_builder.context.devServer) === null || _appContext_builder_context_devServer === void 0 ? void 0 : _appContext_builder_context_devServer.https);
|
|
115671
|
+
const urls = getAddressUrls(isHttps ? "https" : "http", port, (_config_dev = config.dev) === null || _config_dev === void 0 ? void 0 : _config_dev.host);
|
|
115899
115672
|
const routes = !apiOnly ? serverRoutes.filter((route) => route.entryName) : serverRoutes;
|
|
115900
115673
|
let message = "App running at:\n\n";
|
|
115901
115674
|
if ((0, _is.isSingleEntry)(entrypoints) || apiOnly) {
|
|
@@ -116141,31 +115914,6 @@ var require_runtimeExports = __commonJS({
|
|
|
116141
115914
|
}
|
|
116142
115915
|
});
|
|
116143
115916
|
|
|
116144
|
-
// ../../../toolkit/utils/dist/cjs/cli/test.js
|
|
116145
|
-
var require_test = __commonJS({
|
|
116146
|
-
"../../../toolkit/utils/dist/cjs/cli/test.js"(exports) {
|
|
116147
|
-
"use strict";
|
|
116148
|
-
Object.defineProperty(exports, "__esModule", {
|
|
116149
|
-
value: true
|
|
116150
|
-
});
|
|
116151
|
-
Object.defineProperty(exports, "initSnapshotSerializer", {
|
|
116152
|
-
enumerable: true,
|
|
116153
|
-
get: function() {
|
|
116154
|
-
return initSnapshotSerializer;
|
|
116155
|
-
}
|
|
116156
|
-
});
|
|
116157
|
-
var initSnapshotSerializer = (root) => {
|
|
116158
|
-
expect.addSnapshotSerializer({
|
|
116159
|
-
test: (val) => typeof val === "string" && (val.includes("modern.js") || val.includes("node_modules") || val.includes(root)),
|
|
116160
|
-
print: (val) => (
|
|
116161
|
-
// eslint-disable-next-line no-nested-ternary
|
|
116162
|
-
typeof val === "string" ? val.includes("node_modules") ? `"${val.replace(/.+node_modules/, ``).replace(/\\/g, "/")}"` : val.includes("modern.js") ? `"${val.replace(/.+modern\.js/, ``).replace(/\\/g, "/")}"` : `"${val.replace(root, "").replace(/\\/g, "/")}"` : val
|
|
116163
|
-
)
|
|
116164
|
-
});
|
|
116165
|
-
};
|
|
116166
|
-
}
|
|
116167
|
-
});
|
|
116168
|
-
|
|
116169
115917
|
// ../../../toolkit/utils/dist/cjs/cli/watch.js
|
|
116170
115918
|
var require_watch = __commonJS({
|
|
116171
115919
|
"../../../toolkit/utils/dist/cjs/cli/watch.js"(exports) {
|
|
@@ -116262,7 +116010,6 @@ var require_cli = __commonJS({
|
|
|
116262
116010
|
_export_star._(require_require(), exports);
|
|
116263
116011
|
_export_star._(require_routes(), exports);
|
|
116264
116012
|
_export_star._(require_runtimeExports(), exports);
|
|
116265
|
-
_export_star._(require_test(), exports);
|
|
116266
116013
|
_export_star._(require_watch(), exports);
|
|
116267
116014
|
}
|
|
116268
116015
|
});
|
|
@@ -116332,7 +116079,7 @@ var mime = Import.lazy("../compiled/mime-types", require);
|
|
|
116332
116079
|
var chokidar = Import.lazy("../compiled/chokidar", require);
|
|
116333
116080
|
var inquirer = Import.lazy("../compiled/inquirer", require);
|
|
116334
116081
|
|
|
116335
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
116082
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/index.js
|
|
116336
116083
|
var import_lodash6 = __toESM(require_lodash2());
|
|
116337
116084
|
var import_comment_json = __toESM(require_src2());
|
|
116338
116085
|
|
|
@@ -128433,10 +128180,10 @@ var Schema = (
|
|
|
128433
128180
|
}()
|
|
128434
128181
|
);
|
|
128435
128182
|
|
|
128436
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.
|
|
128183
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-formily/dist/esm/prompt.js
|
|
128437
128184
|
var import_inquirer = __toESM(require_inquirer());
|
|
128438
128185
|
|
|
128439
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.
|
|
128186
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-formily/dist/esm/transform.js
|
|
128440
128187
|
var import_lodash2 = __toESM(require_lodash2());
|
|
128441
128188
|
function asyncGeneratorStep9(gen, resolve, reject, _next, _throw, key, arg) {
|
|
128442
128189
|
try {
|
|
@@ -128783,7 +128530,7 @@ function transformForm(schema) {
|
|
|
128783
128530
|
return getQuestionFromSchema(schema, configValue, validateMap, initValue);
|
|
128784
128531
|
}
|
|
128785
128532
|
|
|
128786
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.
|
|
128533
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-formily/dist/esm/prompt.js
|
|
128787
128534
|
function asyncGeneratorStep10(gen, resolve, reject, _next, _throw, key, arg) {
|
|
128788
128535
|
try {
|
|
128789
128536
|
var info = gen[key](arg);
|
|
@@ -129307,7 +129054,7 @@ function _prompt() {
|
|
|
129307
129054
|
return _prompt.apply(this, arguments);
|
|
129308
129055
|
}
|
|
129309
129056
|
|
|
129310
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.
|
|
129057
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-formily@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-formily/dist/esm/inquirer.js
|
|
129311
129058
|
function asyncGeneratorStep11(gen, resolve, reject, _next, _throw, key, arg) {
|
|
129312
129059
|
try {
|
|
129313
129060
|
var info = gen[key](arg);
|
|
@@ -129547,7 +129294,7 @@ var CLIReader = /* @__PURE__ */ function() {
|
|
|
129547
129294
|
return CLIReader2;
|
|
129548
129295
|
}();
|
|
129549
129296
|
|
|
129550
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129297
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/index.js
|
|
129551
129298
|
var import_inquirer2 = __toESM(require_inquirer2());
|
|
129552
129299
|
|
|
129553
129300
|
// ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@2.18.0/node_modules/@modern-js/plugin-i18n/dist/esm-node/index.js
|
|
@@ -129626,7 +129373,7 @@ var I18n = class {
|
|
|
129626
129373
|
}
|
|
129627
129374
|
};
|
|
129628
129375
|
|
|
129629
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129376
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/locale/zh.js
|
|
129630
129377
|
var ZH_LOCALE = {
|
|
129631
129378
|
environment: {
|
|
129632
129379
|
node_version: "请升级 Node 版本至 LIS",
|
|
@@ -129653,7 +129400,7 @@ var ZH_LOCALE = {
|
|
|
129653
129400
|
}
|
|
129654
129401
|
};
|
|
129655
129402
|
|
|
129656
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129403
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/locale/en.js
|
|
129657
129404
|
var EN_LOCALE = {
|
|
129658
129405
|
environment: {
|
|
129659
129406
|
node_version: "please upgrade node to lts version",
|
|
@@ -129680,14 +129427,14 @@ var EN_LOCALE = {
|
|
|
129680
129427
|
}
|
|
129681
129428
|
};
|
|
129682
129429
|
|
|
129683
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129430
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/locale/index.js
|
|
129684
129431
|
var i18n = new I18n();
|
|
129685
129432
|
var localeKeys = i18n.init("zh", {
|
|
129686
129433
|
zh: ZH_LOCALE,
|
|
129687
129434
|
en: EN_LOCALE
|
|
129688
129435
|
});
|
|
129689
129436
|
|
|
129690
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129437
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/utils/transform.js
|
|
129691
129438
|
var import_lodash5 = __toESM(require_lodash2());
|
|
129692
129439
|
function asyncGeneratorStep12(gen, resolve, reject, _next, _throw, key, arg) {
|
|
129693
129440
|
try {
|
|
@@ -129896,7 +129643,7 @@ function transformInquirerSchema(questions) {
|
|
|
129896
129643
|
return questions;
|
|
129897
129644
|
}
|
|
129898
129645
|
|
|
129899
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129646
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/utils/checkUseNvm.js
|
|
129900
129647
|
var import_path4 = __toESM(require("path"));
|
|
129901
129648
|
function asyncGeneratorStep13(gen, resolve, reject, _next, _throw, key, arg) {
|
|
129902
129649
|
try {
|
|
@@ -130160,7 +129907,7 @@ function _checkUseNvm() {
|
|
|
130160
129907
|
return _checkUseNvm.apply(this, arguments);
|
|
130161
129908
|
}
|
|
130162
129909
|
|
|
130163
|
-
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.
|
|
129910
|
+
// ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@2.2.5_@modern-js+codesmith@2.2.5_typescript@5.0.4/node_modules/@modern-js/codesmith-api-app/dist/esm/index.js
|
|
130164
129911
|
function _array_like_to_array(arr, len) {
|
|
130165
129912
|
if (len == null || len > arr.length)
|
|
130166
129913
|
len = arr.length;
|
|
@@ -131188,7 +130935,7 @@ var ZH_LOCALE2 = {
|
|
|
131188
130935
|
function: {
|
|
131189
130936
|
self: "启用可选功能",
|
|
131190
130937
|
question: "请选择功能名称",
|
|
131191
|
-
tailwindcss: "
|
|
130938
|
+
tailwindcss: "启用「Tailwind CSS」 支持",
|
|
131192
130939
|
bff: "启用「BFF」功能",
|
|
131193
130940
|
micro_frontend: "启用「微前端」模式",
|
|
131194
130941
|
i18n: "启用「国际化(i18n)」功能",
|
|
@@ -131477,8 +131224,6 @@ var src_default = (context, generator) => __async(void 0, null, function* () {
|
|
|
131477
131224
|
}
|
|
131478
131225
|
generator.logger.debug(`forge @modern-js/base-generator succeed `);
|
|
131479
131226
|
});
|
|
131480
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
131481
|
-
0 && (module.exports = {});
|
|
131482
131227
|
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
131483
131228
|
/*!
|
|
131484
131229
|
* fill-range <https://github.com/jonschlinkert/fill-range>
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"modern",
|
|
16
16
|
"modern.js"
|
|
17
17
|
],
|
|
18
|
-
"version": "3.1.
|
|
18
|
+
"version": "3.1.22",
|
|
19
19
|
"jsnext:source": "./src/index.ts",
|
|
20
20
|
"types": "./src/index.ts",
|
|
21
21
|
"main": "./dist/index.js",
|
|
@@ -30,15 +30,16 @@
|
|
|
30
30
|
"@types/node": "^14",
|
|
31
31
|
"jest": "^29",
|
|
32
32
|
"typescript": "^5",
|
|
33
|
-
"@
|
|
34
|
-
"@
|
|
35
|
-
"@
|
|
36
|
-
"@
|
|
33
|
+
"@modern-js/generator-common": "3.1.22",
|
|
34
|
+
"@modern-js/generator-utils": "3.1.22",
|
|
35
|
+
"@scripts/build": "2.23.0",
|
|
36
|
+
"@scripts/jest-config": "2.23.0"
|
|
37
37
|
},
|
|
38
38
|
"sideEffects": false,
|
|
39
39
|
"publishConfig": {
|
|
40
40
|
"registry": "https://registry.npmjs.org/",
|
|
41
|
-
"access": "public"
|
|
41
|
+
"access": "public",
|
|
42
|
+
"provenance": true
|
|
42
43
|
},
|
|
43
44
|
"scripts": {
|
|
44
45
|
"new": "modern-lib new",
|