create-vue 3.18.2 → 3.18.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/README.md +1 -1
- package/bundle.js +88 -206
- package/package.json +8 -8
- package/template/base/package.json +4 -4
- package/template/config/cypress/package.json +2 -2
- package/template/config/cypress-ct/package.json +2 -2
- package/template/config/jsx/package.json +3 -3
- package/template/config/nightwatch/package.json +5 -5
- package/template/config/nightwatch-ct/package.json +1 -1
- package/template/config/pinia/package.json +2 -2
- package/template/config/playwright/package.json +1 -1
- package/template/config/prettier/package.json +1 -1
- package/template/config/router/package.json +1 -1
- package/template/config/typescript/package.json +2 -2
- package/template/config/vitest/package.json +3 -3
- package/template/eslint/package.json +2 -2
- package/template/tsconfig/base/package.json +1 -1
- package/template/tsconfig/base/tsconfig.node.json +1 -1
- package/template/tsconfig/nightwatch/nightwatch/tsconfig.json +1 -1
- package/template/tsconfig/playwright/e2e/tsconfig.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# create-vue <a href="https://npmjs.com/package/create-vue"><img src="https://
|
|
1
|
+
# create-vue <a href="https://npmjs.com/package/create-vue"><img src="https://img.shields.io/npm/dw/create-vue" alt="npm package"></a> <a href="https://nodejs.org/en/about/previous-releases"><img src="https://img.shields.io/node/v/create-vue" alt="node compatibility"></a>
|
|
2
2
|
|
|
3
3
|
The recommended way to start a Vite-powered Vue project
|
|
4
4
|
|
package/bundle.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
/*! create-vue v3.18.
|
|
2
|
+
/*! create-vue v3.18.3 | MIT */
|
|
3
3
|
import { createRequire } from "node:module";
|
|
4
4
|
import * as fs from "node:fs";
|
|
5
5
|
import * as path from "node:path";
|
|
@@ -18,16 +18,18 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
18
18
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
19
19
|
var __getProtoOf = Object.getPrototypeOf;
|
|
20
20
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
21
|
-
var
|
|
22
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
23
|
-
};
|
|
21
|
+
var __commonJSMin = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
24
22
|
var __copyProps = (to, from, except, desc) => {
|
|
25
|
-
if (from && typeof from === "object" || typeof from === "function")
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
23
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
24
|
+
for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
25
|
+
key = keys[i];
|
|
26
|
+
if (!__hasOwnProp.call(to, key) && key !== except) {
|
|
27
|
+
__defProp(to, key, {
|
|
28
|
+
get: ((k$2) => from[k$2]).bind(null, key),
|
|
29
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
}
|
|
31
33
|
}
|
|
32
34
|
return to;
|
|
33
35
|
};
|
|
@@ -39,7 +41,7 @@ var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
|
39
41
|
|
|
40
42
|
//#endregion
|
|
41
43
|
//#region node_modules/.pnpm/sisteransi@1.0.5/node_modules/sisteransi/src/index.js
|
|
42
|
-
var require_src = /* @__PURE__ */
|
|
44
|
+
var require_src = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
43
45
|
const ESC = "\x1B";
|
|
44
46
|
const CSI = `${ESC}[`;
|
|
45
47
|
const beep = "\x07";
|
|
@@ -92,11 +94,11 @@ var require_src = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/sisteransi@1.
|
|
|
92
94
|
erase,
|
|
93
95
|
beep
|
|
94
96
|
};
|
|
95
|
-
})
|
|
97
|
+
}));
|
|
96
98
|
|
|
97
99
|
//#endregion
|
|
98
100
|
//#region node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
|
|
99
|
-
var require_picocolors = /* @__PURE__ */
|
|
101
|
+
var require_picocolors = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
100
102
|
let p$1 = process || {}, argv = p$1.argv || [], env = p$1.env || {};
|
|
101
103
|
let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p$1.platform === "win32" || (p$1.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
|
|
102
104
|
let formatter = (open, close, replace = open) => (input) => {
|
|
@@ -161,11 +163,11 @@ var require_picocolors = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/picoco
|
|
|
161
163
|
};
|
|
162
164
|
module.exports = createColors();
|
|
163
165
|
module.exports.createColors = createColors;
|
|
164
|
-
})
|
|
166
|
+
}));
|
|
165
167
|
|
|
166
168
|
//#endregion
|
|
167
169
|
//#region node_modules/.pnpm/@clack+core@0.5.0/node_modules/@clack/core/dist/index.mjs
|
|
168
|
-
var import_src$1 =
|
|
170
|
+
var import_src$1 = require_src();
|
|
169
171
|
var import_picocolors$2 = /* @__PURE__ */ __toESM(require_picocolors(), 1);
|
|
170
172
|
function DD({ onlyFirst: e$1 = !1 } = {}) {
|
|
171
173
|
const t = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?(?:\\u0007|\\u001B\\u005C|\\u009C))", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
|
|
@@ -508,7 +510,7 @@ var gD = Object.defineProperty, vD = (e$1, u$1, t) => u$1 in e$1 ? gD(e$1, u$1,
|
|
|
508
510
|
var x$1 = class {
|
|
509
511
|
constructor(u$1, t = !0) {
|
|
510
512
|
h(this, "input"), h(this, "output"), h(this, "_abortSignal"), h(this, "rl"), h(this, "opts"), h(this, "_render"), h(this, "_track", !1), h(this, "_prevFrame", ""), h(this, "_subscribers", /* @__PURE__ */ new Map()), h(this, "_cursor", 0), h(this, "state", "initial"), h(this, "error", ""), h(this, "value");
|
|
511
|
-
const { input: F$1 = stdin, output: s = stdout, render: i, signal: D$1
|
|
513
|
+
const { input: F$1 = stdin, output: s = stdout, render: i, signal: D$1, ...C$1 } = u$1;
|
|
512
514
|
this.opts = C$1, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = i.bind(this), this._track = t, this._abortSignal = D$1, this.input = F$1, this.output = s;
|
|
513
515
|
}
|
|
514
516
|
unsubscribe() {
|
|
@@ -728,7 +730,7 @@ var TD = Object.defineProperty, jD = (e$1, u$1, t) => u$1 in e$1 ? TD(e$1, u$1,
|
|
|
728
730
|
value: t
|
|
729
731
|
}) : e$1[u$1] = t, U$1 = (e$1, u$1, t) => (jD(e$1, typeof u$1 != "symbol" ? u$1 + "" : u$1, t), t);
|
|
730
732
|
var MD = class extends x$1 {
|
|
731
|
-
constructor({ mask: u$1
|
|
733
|
+
constructor({ mask: u$1, ...t }) {
|
|
732
734
|
super(t), U$1(this, "valueWithCursor", ""), U$1(this, "_mask", "•"), this._mask = u$1 ?? "•", this.on("finalize", () => {
|
|
733
735
|
this.valueWithCursor = this.masked;
|
|
734
736
|
}), this.on("value", () => {
|
|
@@ -812,7 +814,7 @@ var RD = class extends x$1 {
|
|
|
812
814
|
//#endregion
|
|
813
815
|
//#region node_modules/.pnpm/@clack+prompts@0.11.0/node_modules/@clack/prompts/dist/index.mjs
|
|
814
816
|
var import_picocolors$1 = /* @__PURE__ */ __toESM(require_picocolors(), 1);
|
|
815
|
-
var import_src =
|
|
817
|
+
var import_src = require_src();
|
|
816
818
|
function ce() {
|
|
817
819
|
return y.platform !== "win32" ? y.env.TERM !== "linux" : !!y.env.CI || !!y.env.WT_SESSION || !!y.env.TERMINUS_SUBLIME || y.env.ConEmuTask === "{cmd::Cmder}" || y.env.TERM_PROGRAM === "Terminus-Sublime" || y.env.TERM_PROGRAM === "vscode" || y.env.TERM === "xterm-256color" || y.env.TERM === "alacritty" || y.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
818
820
|
}
|
|
@@ -1227,7 +1229,12 @@ ${J}${i.trimStart()}`), r$1 = 3 + stripVTControlCharacters(i.trimStart()).length
|
|
|
1227
1229
|
|
|
1228
1230
|
//#endregion
|
|
1229
1231
|
//#region node_modules/.pnpm/ejs@3.1.10/node_modules/ejs/lib/utils.js
|
|
1230
|
-
|
|
1232
|
+
/**
|
|
1233
|
+
* Private utility functions
|
|
1234
|
+
* @module utils
|
|
1235
|
+
* @private
|
|
1236
|
+
*/
|
|
1237
|
+
var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
1231
1238
|
var regExpChars = /[|\\{}()[\]^$+*?.]/g;
|
|
1232
1239
|
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
1233
1240
|
var hasOwn = function(obj, key) {
|
|
@@ -1383,6 +1390,9 @@ var require_utils = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/
|
|
|
1383
1390
|
if (typeof Object.create == "function") return function() {
|
|
1384
1391
|
return Object.create(null);
|
|
1385
1392
|
};
|
|
1393
|
+
if (!({ __proto__: null } instanceof Object)) return function() {
|
|
1394
|
+
return { __proto__: null };
|
|
1395
|
+
};
|
|
1386
1396
|
return function() {
|
|
1387
1397
|
return {};
|
|
1388
1398
|
};
|
|
@@ -1392,11 +1402,11 @@ var require_utils = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/
|
|
|
1392
1402
|
for (var p$2 in obj) if (hasOwn(obj, p$2)) o$1[p$2] = obj[p$2];
|
|
1393
1403
|
return o$1;
|
|
1394
1404
|
};
|
|
1395
|
-
})
|
|
1405
|
+
}));
|
|
1396
1406
|
|
|
1397
1407
|
//#endregion
|
|
1398
1408
|
//#region node_modules/.pnpm/ejs@3.1.10/node_modules/ejs/package.json
|
|
1399
|
-
var require_package = /* @__PURE__ */
|
|
1409
|
+
var require_package = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1400
1410
|
module.exports = {
|
|
1401
1411
|
"name": "ejs",
|
|
1402
1412
|
"description": "Embedded JavaScript templates",
|
|
@@ -1431,11 +1441,11 @@ var require_package = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.1
|
|
|
1431
1441
|
"engines": { "node": ">=0.10.0" },
|
|
1432
1442
|
"scripts": { "test": "npx jake test" }
|
|
1433
1443
|
};
|
|
1434
|
-
})
|
|
1444
|
+
}));
|
|
1435
1445
|
|
|
1436
1446
|
//#endregion
|
|
1437
1447
|
//#region node_modules/.pnpm/ejs@3.1.10/node_modules/ejs/lib/ejs.js
|
|
1438
|
-
var require_ejs = /* @__PURE__ */
|
|
1448
|
+
var require_ejs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
1439
1449
|
/**
|
|
1440
1450
|
* @file Embedded JavaScript templating engine. {@link http://ejs.co}
|
|
1441
1451
|
* @author Matthew Eernisse <mde@fleegix.org>
|
|
@@ -1529,12 +1539,12 @@ var require_ejs = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/no
|
|
|
1529
1539
|
* @param {Boolean} [isDir=false] whether the parent file path is a directory
|
|
1530
1540
|
* @return {String}
|
|
1531
1541
|
*/
|
|
1532
|
-
exports.resolveInclude = function(name$
|
|
1542
|
+
exports.resolveInclude = function(name$1, filename, isDir) {
|
|
1533
1543
|
var dirname = path$2.dirname;
|
|
1534
1544
|
var extname = path$2.extname;
|
|
1535
1545
|
var resolve = path$2.resolve;
|
|
1536
|
-
var includePath = resolve(isDir ? filename : dirname(filename), name$
|
|
1537
|
-
if (!extname(name$
|
|
1546
|
+
var includePath = resolve(isDir ? filename : dirname(filename), name$1);
|
|
1547
|
+
if (!extname(name$1)) includePath += ".ejs";
|
|
1538
1548
|
return includePath;
|
|
1539
1549
|
};
|
|
1540
1550
|
/**
|
|
@@ -1544,10 +1554,10 @@ var require_ejs = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/no
|
|
|
1544
1554
|
* @param {Array<String>} paths list of possible parent directory paths
|
|
1545
1555
|
* @return {String}
|
|
1546
1556
|
*/
|
|
1547
|
-
function resolvePaths(name$
|
|
1557
|
+
function resolvePaths(name$1, paths) {
|
|
1548
1558
|
var filePath;
|
|
1549
1559
|
if (paths.some(function(v$1) {
|
|
1550
|
-
filePath = exports.resolveInclude(name$
|
|
1560
|
+
filePath = exports.resolveInclude(name$1, v$1, true);
|
|
1551
1561
|
return fs$1.existsSync(filePath);
|
|
1552
1562
|
})) return filePath;
|
|
1553
1563
|
}
|
|
@@ -1873,10 +1883,10 @@ var require_ejs = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/no
|
|
|
1873
1883
|
if (opts.destructuredLocals && opts.destructuredLocals.length) {
|
|
1874
1884
|
var destructuring = " var __locals = (" + opts.localsName + " || {}),\n";
|
|
1875
1885
|
for (var i = 0; i < opts.destructuredLocals.length; i++) {
|
|
1876
|
-
var name$
|
|
1877
|
-
if (!_JS_IDENTIFIER.test(name$
|
|
1886
|
+
var name$1 = opts.destructuredLocals[i];
|
|
1887
|
+
if (!_JS_IDENTIFIER.test(name$1)) throw new Error("destructuredLocals[" + i + "] is not a valid JS identifier.");
|
|
1878
1888
|
if (i > 0) destructuring += ",\n ";
|
|
1879
|
-
destructuring += name$
|
|
1889
|
+
destructuring += name$1 + " = __locals." + name$1;
|
|
1880
1890
|
}
|
|
1881
1891
|
prepended += destructuring + ";\n";
|
|
1882
1892
|
}
|
|
@@ -2099,7 +2109,7 @@ var require_ejs = /* @__PURE__ */ __commonJS({ "node_modules/.pnpm/ejs@3.1.10/no
|
|
|
2099
2109
|
exports.name = _NAME;
|
|
2100
2110
|
/* istanbul ignore if */
|
|
2101
2111
|
if (typeof window != "undefined") window.ejs = exports;
|
|
2102
|
-
})
|
|
2112
|
+
}));
|
|
2103
2113
|
|
|
2104
2114
|
//#endregion
|
|
2105
2115
|
//#region utils/banners.ts
|
|
@@ -2139,8 +2149,8 @@ function sortDependencies(packageJson) {
|
|
|
2139
2149
|
"optionalDependencies"
|
|
2140
2150
|
]) if (packageJson[depType]) {
|
|
2141
2151
|
sorted[depType] = {};
|
|
2142
|
-
Object.keys(packageJson[depType]).sort().forEach((name$
|
|
2143
|
-
sorted[depType][name$
|
|
2152
|
+
Object.keys(packageJson[depType]).sort().forEach((name$1) => {
|
|
2153
|
+
sorted[depType][name$1] = packageJson[depType][name$1];
|
|
2144
2154
|
});
|
|
2145
2155
|
}
|
|
2146
2156
|
return {
|
|
@@ -2235,11 +2245,11 @@ function postOrderDirectoryTraverse(dir, dirCallback, fileCallback) {
|
|
|
2235
2245
|
|
|
2236
2246
|
//#endregion
|
|
2237
2247
|
//#region utils/getCommand.ts
|
|
2238
|
-
function getCommand(packageManager
|
|
2239
|
-
if (scriptName === "install") return packageManager
|
|
2240
|
-
if (scriptName === "build") return packageManager
|
|
2241
|
-
if (args) return packageManager
|
|
2242
|
-
else return packageManager
|
|
2248
|
+
function getCommand(packageManager, scriptName, args) {
|
|
2249
|
+
if (scriptName === "install") return packageManager === "yarn" ? "yarn" : `${packageManager} install`;
|
|
2250
|
+
if (scriptName === "build") return packageManager === "npm" || packageManager === "bun" ? `${packageManager} run build` : `${packageManager} build`;
|
|
2251
|
+
if (args) return packageManager === "npm" ? `npm run ${scriptName} -- ${args}` : `${packageManager} ${scriptName} ${args}`;
|
|
2252
|
+
else return packageManager === "npm" ? `npm run ${scriptName}` : `${packageManager} ${scriptName}`;
|
|
2243
2253
|
}
|
|
2244
2254
|
|
|
2245
2255
|
//#endregion
|
|
@@ -2251,8 +2261,8 @@ const sfcTypeSupportDoc = [
|
|
|
2251
2261
|
"TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types.",
|
|
2252
2262
|
""
|
|
2253
2263
|
].join("\n");
|
|
2254
|
-
function generateReadme({ projectName, packageManager
|
|
2255
|
-
const commandFor = (scriptName, args) => getCommand(packageManager
|
|
2264
|
+
function generateReadme({ projectName, packageManager, needsTypeScript, needsCypress, needsNightwatch, needsCypressCT, needsNightwatchCT, needsPlaywright, needsVitest, needsEslint }) {
|
|
2265
|
+
const commandFor = (scriptName, args) => getCommand(packageManager, scriptName, args);
|
|
2256
2266
|
let readme = `# ${projectName}
|
|
2257
2267
|
|
|
2258
2268
|
This template should help get you started developing with Vue 3 in Vite.
|
|
@@ -2278,7 +2288,7 @@ See [Vite Configuration Reference](https://vite.dev/config/).
|
|
|
2278
2288
|
|
|
2279
2289
|
`;
|
|
2280
2290
|
let installCommand = commandFor("install");
|
|
2281
|
-
if (packageManager
|
|
2291
|
+
if (packageManager === "pnpm" && needsNightwatch) installCommand += `\npnpm approve-builds # for pnpm 10+`;
|
|
2282
2292
|
let npmScriptsDescriptions = `\`\`\`sh
|
|
2283
2293
|
${installCommand}
|
|
2284
2294
|
\`\`\`
|
|
@@ -2430,7 +2440,7 @@ async function getLanguage(localesRoot) {
|
|
|
2430
2440
|
}
|
|
2431
2441
|
|
|
2432
2442
|
//#endregion
|
|
2433
|
-
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.
|
|
2443
|
+
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.1/node_modules/@vue/create-eslint-config/renderEjsFile.js
|
|
2434
2444
|
const templates = {
|
|
2435
2445
|
"./templates/_editorconfig.ejs": "[*.{js,jsx,mjs,cjs,ts,tsx,mts,cts,vue,css,scss,sass,less,styl}]\ncharset = utf-8\nindent_size = 2\nindent_style = space\ninsert_final_newline = true\ntrim_trailing_whitespace = true\nend_of_line = lf\nmax_line_length = 100\n",
|
|
2436
2446
|
"./templates/_gitattributes": "* text=auto eol=lf\n",
|
|
@@ -2443,79 +2453,27 @@ function renderEjsFile(filePath, data) {
|
|
|
2443
2453
|
}
|
|
2444
2454
|
|
|
2445
2455
|
//#endregion
|
|
2446
|
-
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.
|
|
2447
|
-
var
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
var main = "index.js";
|
|
2452
|
-
var bin$1 = { "create-eslint-config": "bin/create-eslint-config.js" };
|
|
2453
|
-
var engines$1 = { "node": "^16.14.0 || >= 18.0.0" };
|
|
2454
|
-
var scripts$1 = {
|
|
2455
|
-
"test": "echo \"Error: no test specified\" && exit 1",
|
|
2456
|
-
"lint": "eslint --fix ."
|
|
2457
|
-
};
|
|
2458
|
-
var repository$1 = {
|
|
2459
|
-
"type": "git",
|
|
2460
|
-
"url": "git+https://github.com/vuejs/create-eslint-config.git"
|
|
2461
|
-
};
|
|
2462
|
-
var keywords$1 = [
|
|
2463
|
-
"vue",
|
|
2464
|
-
"eslint",
|
|
2465
|
-
"config"
|
|
2466
|
-
];
|
|
2467
|
-
var author$1 = "Haoqun Jiang <haoqunjiang+npm@gmail.com>";
|
|
2468
|
-
var license$1 = "MIT";
|
|
2469
|
-
var bugs$1 = { "url": "https://github.com/vuejs/create-eslint-config/issues" };
|
|
2470
|
-
var homepage$1 = "https://github.com/vuejs/create-eslint-config#readme";
|
|
2471
|
-
var publishConfig$1 = {
|
|
2472
|
-
"access": "public",
|
|
2473
|
-
"provenance": true
|
|
2474
|
-
};
|
|
2475
|
-
var dependencies = {
|
|
2476
|
-
"ejs": "^3.1.10",
|
|
2477
|
-
"enquirer": "^2.4.1",
|
|
2478
|
-
"kolorist": "^1.8.0"
|
|
2479
|
-
};
|
|
2480
|
-
var devDependencies$2 = {
|
|
2481
|
-
"@eslint/js": "^9.37.0",
|
|
2482
|
-
"@prettier/plugin-oxc": "^0.0.4",
|
|
2483
|
-
"@types/node": "^22.18.10",
|
|
2456
|
+
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.1/node_modules/@vue/create-eslint-config/package.json
|
|
2457
|
+
var devDependencies$1 = {
|
|
2458
|
+
"@eslint/js": "^9.39.1",
|
|
2459
|
+
"@prettier/plugin-oxc": "^0.0.5",
|
|
2460
|
+
"@types/node": "^22.19.1",
|
|
2484
2461
|
"@vue/eslint-config-prettier": "^10.2.0",
|
|
2485
2462
|
"@vue/eslint-config-typescript": "^14.6.0",
|
|
2486
|
-
"eslint": "^9.
|
|
2487
|
-
"eslint-plugin-oxlint": "~1.
|
|
2488
|
-
"eslint-plugin-vue": "~10.5.
|
|
2489
|
-
"globals": "^16.
|
|
2463
|
+
"eslint": "^9.39.1",
|
|
2464
|
+
"eslint-plugin-oxlint": "~1.29.0",
|
|
2465
|
+
"eslint-plugin-vue": "~10.5.1",
|
|
2466
|
+
"globals": "^16.5.0",
|
|
2490
2467
|
"jiti": "^2.6.1",
|
|
2491
2468
|
"npm-run-all2": "^8.0.4",
|
|
2492
|
-
"oxlint": "~1.
|
|
2469
|
+
"oxlint": "~1.29.0",
|
|
2493
2470
|
"prettier": "3.6.2",
|
|
2494
2471
|
"typescript": "~5.9.0"
|
|
2495
2472
|
};
|
|
2496
|
-
var package_default$2 = {
|
|
2497
|
-
name: name$1,
|
|
2498
|
-
version: version$1,
|
|
2499
|
-
description: description$1,
|
|
2500
|
-
type: type$1,
|
|
2501
|
-
main,
|
|
2502
|
-
bin: bin$1,
|
|
2503
|
-
engines: engines$1,
|
|
2504
|
-
scripts: scripts$1,
|
|
2505
|
-
repository: repository$1,
|
|
2506
|
-
keywords: keywords$1,
|
|
2507
|
-
author: author$1,
|
|
2508
|
-
license: license$1,
|
|
2509
|
-
bugs: bugs$1,
|
|
2510
|
-
homepage: homepage$1,
|
|
2511
|
-
publishConfig: publishConfig$1,
|
|
2512
|
-
dependencies,
|
|
2513
|
-
devDependencies: devDependencies$2
|
|
2514
|
-
};
|
|
2515
2473
|
|
|
2516
2474
|
//#endregion
|
|
2517
|
-
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.
|
|
2518
|
-
const versionMap =
|
|
2475
|
+
//#region node_modules/.pnpm/@vue+create-eslint-config@0.13.1/node_modules/@vue/create-eslint-config/index.js
|
|
2476
|
+
const versionMap = devDependencies$1;
|
|
2519
2477
|
function createConfig({ styleGuide = "default", hasTypeScript = false, needsPrettier = false, needsOxlint = false, additionalConfigs = [] }) {
|
|
2520
2478
|
const pickDependencies = (keys) => pickKeysFromObject(versionMap, keys);
|
|
2521
2479
|
const pkg = {
|
|
@@ -2571,14 +2529,14 @@ function createConfig({ styleGuide = "default", hasTypeScript = false, needsPret
|
|
|
2571
2529
|
configsBeforeVuePlugin,
|
|
2572
2530
|
configsAfterVuePlugin
|
|
2573
2531
|
};
|
|
2574
|
-
const files
|
|
2575
|
-
if (hasTypeScript) files
|
|
2576
|
-
else files
|
|
2577
|
-
if (needsPrettier) files
|
|
2578
|
-
files
|
|
2532
|
+
const files = { ".editorconfig": renderEjsFile("./templates/_editorconfig.ejs", templateData) };
|
|
2533
|
+
if (hasTypeScript) files["eslint.config.ts"] = renderEjsFile("./templates/eslint.config.ts.ejs", templateData);
|
|
2534
|
+
else files["eslint.config.js"] = renderEjsFile("./templates/eslint.config.js.ejs", templateData);
|
|
2535
|
+
if (needsPrettier) files[".prettierrc.json"] = renderEjsFile("./templates/_prettierrc.json.ejs", templateData);
|
|
2536
|
+
files[".gitattributes"] = renderEjsFile("./templates/_gitattributes", {});
|
|
2579
2537
|
return {
|
|
2580
2538
|
pkg,
|
|
2581
|
-
files
|
|
2539
|
+
files
|
|
2582
2540
|
};
|
|
2583
2541
|
}
|
|
2584
2542
|
/**
|
|
@@ -2614,18 +2572,17 @@ function deepMerge(target, obj) {
|
|
|
2614
2572
|
|
|
2615
2573
|
//#endregion
|
|
2616
2574
|
//#region template/eslint/package.json
|
|
2617
|
-
var devDependencies
|
|
2618
|
-
"@vitest/eslint-plugin": "^1.
|
|
2575
|
+
var devDependencies = {
|
|
2576
|
+
"@vitest/eslint-plugin": "^1.5.0",
|
|
2619
2577
|
"eslint-plugin-cypress": "^5.2.0",
|
|
2620
|
-
"eslint-plugin-playwright": "^2.
|
|
2578
|
+
"eslint-plugin-playwright": "^2.3.0"
|
|
2621
2579
|
};
|
|
2622
|
-
var package_default$1 = { devDependencies: devDependencies$1 };
|
|
2623
2580
|
|
|
2624
2581
|
//#endregion
|
|
2625
2582
|
//#region utils/renderEslint.ts
|
|
2626
|
-
const eslintDeps =
|
|
2583
|
+
const eslintDeps = devDependencies;
|
|
2627
2584
|
function renderEslint(rootDir, { needsTypeScript, needsVitest, needsCypress, needsCypressCT, needsOxlint, needsPrettier, needsPlaywright }) {
|
|
2628
|
-
const { pkg, files
|
|
2585
|
+
const { pkg, files } = createConfig({
|
|
2629
2586
|
styleGuide: "default",
|
|
2630
2587
|
hasTypeScript: needsTypeScript,
|
|
2631
2588
|
needsOxlint,
|
|
@@ -2641,7 +2598,7 @@ function renderEslint(rootDir, { needsTypeScript, needsVitest, needsCypress, nee
|
|
|
2641
2598
|
const packageJsonPath = path.resolve(rootDir, "package.json");
|
|
2642
2599
|
const updatedPkg = sortDependencies(deepMerge_default(JSON.parse(fs.readFileSync(packageJsonPath, "utf8")), pkg));
|
|
2643
2600
|
fs.writeFileSync(packageJsonPath, JSON.stringify(updatedPkg, null, 2) + "\n", "utf8");
|
|
2644
|
-
for (const [fileName, content] of Object.entries(files
|
|
2601
|
+
for (const [fileName, content] of Object.entries(files)) {
|
|
2645
2602
|
const fullPath = path.resolve(rootDir, fileName);
|
|
2646
2603
|
fs.writeFileSync(fullPath, content, "utf8");
|
|
2647
2604
|
}
|
|
@@ -2721,86 +2678,11 @@ function emptyRouterConfig(rootDir, needsTypeScript) {
|
|
|
2721
2678
|
//#endregion
|
|
2722
2679
|
//#region package.json
|
|
2723
2680
|
var name = "create-vue";
|
|
2724
|
-
var version = "3.18.
|
|
2725
|
-
var description = "🛠️ The recommended way to start a Vite-powered Vue project";
|
|
2726
|
-
var type = "module";
|
|
2727
|
-
var packageManager = "pnpm@10.18.3";
|
|
2728
|
-
var bin = { "create-vue": "bundle.js" };
|
|
2729
|
-
var files = [
|
|
2730
|
-
"locales",
|
|
2731
|
-
"bundle.js",
|
|
2732
|
-
"template",
|
|
2733
|
-
"!template/**/node_modules/.bin/*"
|
|
2734
|
-
];
|
|
2735
|
-
var engines = { "node": "^20.19.0 || >=22.12.0" };
|
|
2736
|
-
var scripts = {
|
|
2737
|
-
"prepare": "husky",
|
|
2738
|
-
"format": "prettier --write . --experimental-cli",
|
|
2739
|
-
"build": "rolldown -c rolldown.config.ts",
|
|
2740
|
-
"snapshot": "zx ./scripts/snapshot.mjs",
|
|
2741
|
-
"pretest": "pnpm run build && pnpm run snapshot",
|
|
2742
|
-
"test": "zx ./scripts/test.mjs",
|
|
2743
|
-
"test:unit": "vitest",
|
|
2744
|
-
"preversion": "git fetch && git status -uno | grep -q 'Your branch is up to date'",
|
|
2745
|
-
"postversion": "zx ./scripts/postversion.mjs",
|
|
2746
|
-
"prepublishOnly": "pnpm run build"
|
|
2747
|
-
};
|
|
2748
|
-
var repository = {
|
|
2749
|
-
"type": "git",
|
|
2750
|
-
"url": "git+https://github.com/vuejs/create-vue.git"
|
|
2751
|
-
};
|
|
2752
|
-
var keywords = [];
|
|
2753
|
-
var author = "Haoqun Jiang <npm@haoqun.me>";
|
|
2754
|
-
var license = "MIT";
|
|
2755
|
-
var bugs = { "url": "https://github.com/vuejs/create-vue/issues" };
|
|
2756
|
-
var homepage = "https://github.com/vuejs/create-vue#readme";
|
|
2757
|
-
var devDependencies = {
|
|
2758
|
-
"@clack/prompts": "^0.11.0",
|
|
2759
|
-
"@tsconfig/node22": "^22.0.2",
|
|
2760
|
-
"@types/eslint": "^9.6.1",
|
|
2761
|
-
"@types/node": "^22.18.12",
|
|
2762
|
-
"@types/prompts": "^2.4.9",
|
|
2763
|
-
"@vue/create-eslint-config": "^0.13.0",
|
|
2764
|
-
"@vue/tsconfig": "^0.8.1",
|
|
2765
|
-
"ejs": "^3.1.10",
|
|
2766
|
-
"husky": "^9.1.7",
|
|
2767
|
-
"lint-staged": "^16.2.5",
|
|
2768
|
-
"picocolors": "^1.1.1",
|
|
2769
|
-
"prettier": "3.6.2",
|
|
2770
|
-
"rolldown": "1.0.0-beta.43",
|
|
2771
|
-
"rollup-plugin-license": "^3.6.0",
|
|
2772
|
-
"vitest": "^3.2.4",
|
|
2773
|
-
"zx": "^8.8.5"
|
|
2774
|
-
};
|
|
2775
|
-
var lint_staged = { "*.{js,ts,vue,json}": ["prettier --write"] };
|
|
2776
|
-
var publishConfig = {
|
|
2777
|
-
"access": "public",
|
|
2778
|
-
"provenance": true
|
|
2779
|
-
};
|
|
2780
|
-
var package_default = {
|
|
2781
|
-
name,
|
|
2782
|
-
version,
|
|
2783
|
-
description,
|
|
2784
|
-
type,
|
|
2785
|
-
packageManager,
|
|
2786
|
-
bin,
|
|
2787
|
-
files,
|
|
2788
|
-
engines,
|
|
2789
|
-
scripts,
|
|
2790
|
-
repository,
|
|
2791
|
-
keywords,
|
|
2792
|
-
author,
|
|
2793
|
-
license,
|
|
2794
|
-
bugs,
|
|
2795
|
-
homepage,
|
|
2796
|
-
devDependencies,
|
|
2797
|
-
"lint-staged": lint_staged,
|
|
2798
|
-
publishConfig
|
|
2799
|
-
};
|
|
2681
|
+
var version = "3.18.3";
|
|
2800
2682
|
|
|
2801
2683
|
//#endregion
|
|
2802
2684
|
//#region index.ts
|
|
2803
|
-
var import_picocolors =
|
|
2685
|
+
var import_picocolors = require_picocolors();
|
|
2804
2686
|
var import_ejs = /* @__PURE__ */ __toESM(require_ejs(), 1);
|
|
2805
2687
|
const language = await getLanguage(fileURLToPath(new URL("./locales", import.meta.url)));
|
|
2806
2688
|
const FEATURE_FLAGS = [
|
|
@@ -2872,9 +2754,9 @@ function toValidPackageName(projectName) {
|
|
|
2872
2754
|
}
|
|
2873
2755
|
function canSkipEmptying(dir) {
|
|
2874
2756
|
if (!fs.existsSync(dir)) return true;
|
|
2875
|
-
const files
|
|
2876
|
-
if (files
|
|
2877
|
-
if (files
|
|
2757
|
+
const files = fs.readdirSync(dir);
|
|
2758
|
+
if (files.length === 0) return true;
|
|
2759
|
+
if (files.length === 1 && files[0] === ".git") {
|
|
2878
2760
|
dotGitDirectoryState.hasDotGitDirectory = true;
|
|
2879
2761
|
return true;
|
|
2880
2762
|
}
|
|
@@ -2966,7 +2848,7 @@ async function init() {
|
|
|
2966
2848
|
process.exit(0);
|
|
2967
2849
|
}
|
|
2968
2850
|
if (argv$1.version) {
|
|
2969
|
-
console.log(`${
|
|
2851
|
+
console.log(`${name} v${version}`);
|
|
2970
2852
|
process.exit(0);
|
|
2971
2853
|
}
|
|
2972
2854
|
const isFeatureFlagsUsed = FEATURE_FLAGS.some((flag) => typeof argv$1[flag] === "boolean");
|
|
@@ -3175,10 +3057,10 @@ async function init() {
|
|
|
3175
3057
|
if (needsRouter) emptyRouterConfig(root, needsTypeScript);
|
|
3176
3058
|
}
|
|
3177
3059
|
const userAgent = process.env.npm_config_user_agent ?? "";
|
|
3178
|
-
const packageManager
|
|
3060
|
+
const packageManager = /pnpm/.test(userAgent) ? "pnpm" : /yarn/.test(userAgent) ? "yarn" : /bun/.test(userAgent) ? "bun" : "npm";
|
|
3179
3061
|
fs.writeFileSync(path.resolve(root, "README.md"), generateReadme({
|
|
3180
3062
|
projectName: result.projectName ?? result.packageName ?? defaultProjectName,
|
|
3181
|
-
packageManager
|
|
3063
|
+
packageManager,
|
|
3182
3064
|
needsTypeScript,
|
|
3183
3065
|
needsVitest,
|
|
3184
3066
|
needsCypress,
|
|
@@ -3193,9 +3075,9 @@ async function init() {
|
|
|
3193
3075
|
const cdProjectName = path.relative(cwd, root);
|
|
3194
3076
|
outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(`cd ${cdProjectName.includes(" ") ? `"${cdProjectName}"` : cdProjectName}`))}\n`;
|
|
3195
3077
|
}
|
|
3196
|
-
outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager
|
|
3197
|
-
if (needsPrettier) outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager
|
|
3198
|
-
outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager
|
|
3078
|
+
outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager, "install")))}\n`;
|
|
3079
|
+
if (needsPrettier) outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager, "format")))}\n`;
|
|
3080
|
+
outroMessage += ` ${(0, import_picocolors.bold)((0, import_picocolors.green)(getCommand(packageManager, "dev")))}\n`;
|
|
3199
3081
|
if (!dotGitDirectoryState.hasDotGitDirectory) outroMessage += `
|
|
3200
3082
|
${(0, import_picocolors.dim)("|")} ${language.infos.optionalGitCommand}
|
|
3201
3083
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-vue",
|
|
3
|
-
"version": "3.18.
|
|
3
|
+
"version": "3.18.3",
|
|
4
4
|
"description": "🛠️ The recommended way to start a Vite-powered Vue project",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -28,25 +28,25 @@
|
|
|
28
28
|
"homepage": "https://github.com/vuejs/create-vue#readme",
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@clack/prompts": "^0.11.0",
|
|
31
|
-
"@tsconfig/
|
|
31
|
+
"@tsconfig/node24": "^24.0.3",
|
|
32
32
|
"@types/eslint": "^9.6.1",
|
|
33
|
-
"@types/node": "^
|
|
33
|
+
"@types/node": "^24.10.1",
|
|
34
34
|
"@types/prompts": "^2.4.9",
|
|
35
|
-
"@vue/create-eslint-config": "^0.13.
|
|
35
|
+
"@vue/create-eslint-config": "^0.13.1",
|
|
36
36
|
"@vue/tsconfig": "^0.8.1",
|
|
37
37
|
"ejs": "^3.1.10",
|
|
38
38
|
"husky": "^9.1.7",
|
|
39
|
-
"lint-staged": "^16.2.
|
|
39
|
+
"lint-staged": "^16.2.7",
|
|
40
40
|
"picocolors": "^1.1.1",
|
|
41
41
|
"prettier": "3.6.2",
|
|
42
|
-
"rolldown": "1.0.0-beta.
|
|
42
|
+
"rolldown": "1.0.0-beta.52",
|
|
43
43
|
"rollup-plugin-license": "^3.6.0",
|
|
44
|
-
"vitest": "^
|
|
44
|
+
"vitest": "^4.0.14",
|
|
45
45
|
"zx": "^8.8.5"
|
|
46
46
|
},
|
|
47
47
|
"lint-staged": {
|
|
48
48
|
"*.{js,ts,vue,json}": [
|
|
49
|
-
"prettier --write"
|
|
49
|
+
"prettier --write --experimental-cli"
|
|
50
50
|
]
|
|
51
51
|
},
|
|
52
52
|
"publishConfig": {
|
|
@@ -10,11 +10,11 @@
|
|
|
10
10
|
"preview": "vite preview"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"vue": "^3.5.
|
|
13
|
+
"vue": "^3.5.25"
|
|
14
14
|
},
|
|
15
15
|
"devDependencies": {
|
|
16
|
-
"@vitejs/plugin-vue": "^6.0.
|
|
17
|
-
"vite": "^7.
|
|
18
|
-
"vite-plugin-vue-devtools": "^8.0.
|
|
16
|
+
"@vitejs/plugin-vue": "^6.0.2",
|
|
17
|
+
"vite": "^7.2.4",
|
|
18
|
+
"vite-plugin-vue-devtools": "^8.0.5"
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"test:e2e:dev": "start-server-and-test 'vite dev --port 4173' http://localhost:4173 'cypress open --e2e'"
|
|
6
6
|
},
|
|
7
7
|
"devDependencies": {
|
|
8
|
-
"cypress": "^15.
|
|
9
|
-
"start-server-and-test": "^2.1.
|
|
8
|
+
"cypress": "^15.7.0",
|
|
9
|
+
"start-server-and-test": "^2.1.3"
|
|
10
10
|
}
|
|
11
11
|
}
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
},
|
|
5
5
|
"devDependencies": {
|
|
6
6
|
"@nightwatch/vue": "^3.1.2",
|
|
7
|
-
"@vitejs/plugin-vue": "^6.0.
|
|
8
|
-
"chromedriver": "^
|
|
9
|
-
"geckodriver": "^6.0
|
|
10
|
-
"nightwatch": "^3.12.
|
|
7
|
+
"@vitejs/plugin-vue": "^6.0.2",
|
|
8
|
+
"chromedriver": "^142.0.3",
|
|
9
|
+
"geckodriver": "^6.1.0",
|
|
10
|
+
"nightwatch": "^3.12.3",
|
|
11
11
|
"ts-node": "^10.9.2",
|
|
12
|
-
"vite": "^7.
|
|
12
|
+
"vite": "^7.2.4",
|
|
13
13
|
"vite-plugin-nightwatch": "^0.4.6"
|
|
14
14
|
}
|
|
15
15
|
}
|