sv 1.0.0-next.7 → 1.0.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/{addons-DWX20ipF.mjs → addons-So36TZLY.mjs} +299 -230
- package/dist/bin.d.mts +1 -1
- package/dist/bin.mjs +145 -95
- package/dist/{engine-BKdrqoIo.d.mts → engine-D2x5kvrf.d.mts} +146 -135
- package/dist/{engine-w0Kq5hjN.mjs → engine-Do1htOYy.mjs} +131 -91
- package/dist/shared.json +2 -2
- package/dist/src/index.d.mts +3 -7
- package/dist/src/index.mjs +2 -2
- package/dist/src/testing.d.mts +26 -37
- package/dist/src/testing.mjs +48 -34
- package/dist/templates/addon/package.json +3 -3
- package/dist/templates/demo/files.types=checkjs.json +1 -1
- package/dist/templates/demo/files.types=none.json +1 -1
- package/dist/templates/demo/files.types=typescript.json +1 -1
- package/dist/templates/demo/package.json +3 -3
- package/dist/templates/library/package.json +3 -3
- package/dist/templates/minimal/package.json +3 -3
- package/package.json +14 -3
- package/dist/templates/demo/assets/src/lib/images/svelte-welcome.webp +0 -0
package/dist/src/testing.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { S as create, b as exec, bt as __require, l as
|
|
1
|
+
import { S as create, b as exec, bt as __require, l as addAllowBuildsIfPnpm, t as add, x as execSync, xt as __toESM, yt as __commonJSMin } from "../engine-Do1htOYy.mjs";
|
|
2
2
|
import fs from "node:fs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import V from "node:process";
|
|
@@ -350,16 +350,25 @@ var require_stream_combiner = /* @__PURE__ */ __commonJSMin(((exports, module) =
|
|
|
350
350
|
//#endregion
|
|
351
351
|
//#region ../../node_modules/.pnpm/event-stream@3.3.4/node_modules/event-stream/index.js
|
|
352
352
|
var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
353
|
-
var Stream = __require("stream").Stream
|
|
354
|
-
es
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
353
|
+
var Stream = __require("stream").Stream;
|
|
354
|
+
var es = exports;
|
|
355
|
+
var through = require_through();
|
|
356
|
+
var from = require_from();
|
|
357
|
+
var duplex = require_duplexer();
|
|
358
|
+
var map = require_map_stream();
|
|
359
|
+
var pause = require_pause_stream();
|
|
360
|
+
var split = require_split();
|
|
361
|
+
var pipeline = require_stream_combiner();
|
|
362
|
+
var immediately = global.setImmediate || process.nextTick;
|
|
363
|
+
es.Stream = Stream;
|
|
364
|
+
es.through = through;
|
|
365
|
+
es.from = from;
|
|
366
|
+
es.duplex = duplex;
|
|
367
|
+
es.map = map;
|
|
368
|
+
es.pause = pause;
|
|
369
|
+
es.split = split;
|
|
370
|
+
es.pipeline = es.connect = es.pipe = pipeline;
|
|
371
|
+
es.concat = es.merge = function() {
|
|
363
372
|
var toMerge = [].slice.call(arguments);
|
|
364
373
|
if (toMerge.length === 1 && toMerge[0] instanceof Array) toMerge = toMerge[0];
|
|
365
374
|
var stream = new Stream();
|
|
@@ -389,7 +398,7 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
389
398
|
};
|
|
390
399
|
return stream;
|
|
391
400
|
};
|
|
392
|
-
es
|
|
401
|
+
es.writeArray = function(done) {
|
|
393
402
|
if ("function" !== typeof done) throw new Error("function writeArray (done): done must be function");
|
|
394
403
|
var a = new Stream(), array = [], isDone = false;
|
|
395
404
|
a.write = function(l) {
|
|
@@ -408,7 +417,7 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
408
417
|
};
|
|
409
418
|
return a;
|
|
410
419
|
};
|
|
411
|
-
es
|
|
420
|
+
es.readArray = function(array) {
|
|
412
421
|
var stream = new Stream(), i = 0, paused = false, ended = false;
|
|
413
422
|
stream.readable = true;
|
|
414
423
|
stream.writable = false;
|
|
@@ -430,7 +439,7 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
430
439
|
};
|
|
431
440
|
return stream;
|
|
432
441
|
};
|
|
433
|
-
es
|
|
442
|
+
es.readable = function(func, continueOnError) {
|
|
434
443
|
var stream = new Stream(), i = 0, paused = false, ended = false, reading = false;
|
|
435
444
|
stream.readable = true;
|
|
436
445
|
stream.writable = false;
|
|
@@ -471,8 +480,8 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
471
480
|
};
|
|
472
481
|
return stream;
|
|
473
482
|
};
|
|
474
|
-
es
|
|
475
|
-
return es
|
|
483
|
+
es.mapSync = function(sync) {
|
|
484
|
+
return es.through(function write(data) {
|
|
476
485
|
var mappedData;
|
|
477
486
|
try {
|
|
478
487
|
mappedData = sync(data);
|
|
@@ -482,20 +491,20 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
482
491
|
if (mappedData !== void 0) this.emit("data", mappedData);
|
|
483
492
|
});
|
|
484
493
|
};
|
|
485
|
-
es
|
|
486
|
-
return es
|
|
494
|
+
es.log = function(name) {
|
|
495
|
+
return es.through(function(data) {
|
|
487
496
|
[].slice.call(arguments);
|
|
488
497
|
if (name) console.error(name, data);
|
|
489
498
|
else console.error(data);
|
|
490
499
|
this.emit("data", data);
|
|
491
500
|
});
|
|
492
501
|
};
|
|
493
|
-
es
|
|
494
|
-
return es
|
|
502
|
+
es.child = function(child) {
|
|
503
|
+
return es.duplex(child.stdin, child.stdout);
|
|
495
504
|
};
|
|
496
|
-
es
|
|
505
|
+
es.parse = function(options) {
|
|
497
506
|
var emitError = !!(options ? options.error : false);
|
|
498
|
-
return es
|
|
507
|
+
return es.through(function(data) {
|
|
499
508
|
var obj;
|
|
500
509
|
try {
|
|
501
510
|
if (data) obj = JSON.parse(data.toString());
|
|
@@ -506,28 +515,28 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
506
515
|
if (obj !== void 0) this.emit("data", obj);
|
|
507
516
|
});
|
|
508
517
|
};
|
|
509
|
-
es
|
|
518
|
+
es.stringify = function() {
|
|
510
519
|
var Buffer = __require("buffer").Buffer;
|
|
511
|
-
return es
|
|
520
|
+
return es.mapSync(function(e) {
|
|
512
521
|
return JSON.stringify(Buffer.isBuffer(e) ? e.toString() : e) + "\n";
|
|
513
522
|
});
|
|
514
523
|
};
|
|
515
|
-
es
|
|
516
|
-
return es
|
|
524
|
+
es.replace = function(from, to) {
|
|
525
|
+
return es.pipeline(es.split(from), es.join(to));
|
|
517
526
|
};
|
|
518
|
-
es
|
|
519
|
-
if ("function" === typeof str) return es
|
|
527
|
+
es.join = function(str) {
|
|
528
|
+
if ("function" === typeof str) return es.wait(str);
|
|
520
529
|
var first = true;
|
|
521
|
-
return es
|
|
530
|
+
return es.through(function(data) {
|
|
522
531
|
if (!first) this.emit("data", str);
|
|
523
532
|
first = false;
|
|
524
533
|
this.emit("data", data);
|
|
525
534
|
return true;
|
|
526
535
|
});
|
|
527
536
|
};
|
|
528
|
-
es
|
|
537
|
+
es.wait = function(callback) {
|
|
529
538
|
var arr = [];
|
|
530
|
-
return es
|
|
539
|
+
return es.through(function(data) {
|
|
531
540
|
arr.push(data);
|
|
532
541
|
}, function() {
|
|
533
542
|
var body = Buffer.isBuffer(arr[0]) ? Buffer.concat(arr) : arr.join("");
|
|
@@ -536,14 +545,15 @@ var require_event_stream = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
536
545
|
if (callback) callback(null, body);
|
|
537
546
|
});
|
|
538
547
|
};
|
|
539
|
-
es
|
|
548
|
+
es.pipeable = function() {
|
|
540
549
|
throw new Error("[EVENT-STREAM] es.pipeable is deprecated");
|
|
541
550
|
};
|
|
542
551
|
}));
|
|
543
552
|
//#endregion
|
|
544
553
|
//#region src/testing.ts
|
|
545
554
|
var import_ps_tree = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
546
|
-
var spawn = __require("child_process").spawn
|
|
555
|
+
var spawn = __require("child_process").spawn;
|
|
556
|
+
var es = require_event_stream();
|
|
547
557
|
module.exports = function childrenOfPid(pid, callback) {
|
|
548
558
|
var headers = null;
|
|
549
559
|
if (typeof callback !== "function") throw new Error("childrenOfPid(pid, callback) expects callback");
|
|
@@ -826,7 +836,11 @@ function createSetupTest(vitest, playwright) {
|
|
|
826
836
|
options: kind.options,
|
|
827
837
|
packageManager: "pnpm"
|
|
828
838
|
});
|
|
829
|
-
|
|
839
|
+
addAllowBuildsIfPnpm({
|
|
840
|
+
cwd,
|
|
841
|
+
packageManager: "pnpm",
|
|
842
|
+
packages: ["esbuild"]
|
|
843
|
+
});
|
|
830
844
|
}
|
|
831
845
|
const installDir = path.resolve(cwd, testName);
|
|
832
846
|
const install = await exec("pnpm", ["install"], { nodeOptions: { cwd: installDir } });
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
"access": "public"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
|
-
"sv": "^1.0.0
|
|
25
|
+
"sv": "^1.0.0"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"sv": "^1.0.0
|
|
29
|
-
"@sveltejs/sv-utils": "^1.0.0
|
|
28
|
+
"sv": "^1.0.0",
|
|
29
|
+
"@sveltejs/sv-utils": "^1.0.0",
|
|
30
30
|
"@playwright/test": "^1.60.0",
|
|
31
31
|
"@types/node": "^25.9.1",
|
|
32
32
|
"tsdown": "^0.22.1",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
},
|
|
10
10
|
{
|
|
11
11
|
"name": "src/routes/+page.svelte",
|
|
12
|
-
"contents": "<script>\n\timport
|
|
12
|
+
"contents": "<script>\n\timport welcome from '#lib/images/svelte-welcome.png';\n\timport Counter from './Counter.svelte';\n</script>\n\n<svelte:head>\n\t<title>Home</title>\n\t<meta name=\"description\" content=\"Svelte demo app\" />\n</svelte:head>\n\n<section>\n\t<h1>\n\t\t<span class=\"welcome\">\n\t\t\t<img class=\"welcome-image\" src={welcome} alt=\"Welcome\" />\n\t\t</span>\n\n\t\tto your new<br />SvelteKit app\n\t</h1>\n\n\t<h2>\n\t\ttry editing <strong>src/routes/+page.svelte</strong>\n\t</h2>\n\n\t<Counter />\n</section>\n\n<style>\n\tsection {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: center;\n\t\talign-items: center;\n\t\tflex: 0.6;\n\t}\n\n\th1 {\n\t\twidth: 100%;\n\t}\n\n\t.welcome {\n\t\tdisplay: block;\n\t\tposition: relative;\n\t\twidth: 100%;\n\t\theight: 0;\n\t\tpadding: 0 0 calc(100% * 495 / 2048) 0;\n\t}\n\n\t.welcome-image {\n\t\tposition: absolute;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\ttop: 0;\n\t\tdisplay: block;\n\t}\n</style>\n"
|
|
13
13
|
},
|
|
14
14
|
{
|
|
15
15
|
"name": "src/routes/+page.js",
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
},
|
|
6
6
|
{
|
|
7
7
|
"name": "src/routes/+page.svelte",
|
|
8
|
-
"contents": "<script>\n\timport
|
|
8
|
+
"contents": "<script>\n\timport welcome from '#lib/images/svelte-welcome.png';\n\timport Counter from './Counter.svelte';\n</script>\n\n<svelte:head>\n\t<title>Home</title>\n\t<meta name=\"description\" content=\"Svelte demo app\" />\n</svelte:head>\n\n<section>\n\t<h1>\n\t\t<span class=\"welcome\">\n\t\t\t<img class=\"welcome-image\" src={welcome} alt=\"Welcome\" />\n\t\t</span>\n\n\t\tto your new<br />SvelteKit app\n\t</h1>\n\n\t<h2>\n\t\ttry editing <strong>src/routes/+page.svelte</strong>\n\t</h2>\n\n\t<Counter />\n</section>\n\n<style>\n\tsection {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: center;\n\t\talign-items: center;\n\t\tflex: 0.6;\n\t}\n\n\th1 {\n\t\twidth: 100%;\n\t}\n\n\t.welcome {\n\t\tdisplay: block;\n\t\tposition: relative;\n\t\twidth: 100%;\n\t\theight: 0;\n\t\tpadding: 0 0 calc(100% * 495 / 2048) 0;\n\t}\n\n\t.welcome-image {\n\t\tposition: absolute;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\ttop: 0;\n\t\tdisplay: block;\n\t}\n</style>\n"
|
|
9
9
|
},
|
|
10
10
|
{
|
|
11
11
|
"name": "src/routes/+page.js",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
},
|
|
10
10
|
{
|
|
11
11
|
"name": "src/routes/+page.svelte",
|
|
12
|
-
"contents": "<script lang=\"ts\">\n\timport
|
|
12
|
+
"contents": "<script lang=\"ts\">\n\timport welcome from '#lib/images/svelte-welcome.png';\n\timport Counter from './Counter.svelte';\n</script>\n\n<svelte:head>\n\t<title>Home</title>\n\t<meta name=\"description\" content=\"Svelte demo app\" />\n</svelte:head>\n\n<section>\n\t<h1>\n\t\t<span class=\"welcome\">\n\t\t\t<img class=\"welcome-image\" src={welcome} alt=\"Welcome\" />\n\t\t</span>\n\n\t\tto your new<br />SvelteKit app\n\t</h1>\n\n\t<h2>\n\t\ttry editing <strong>src/routes/+page.svelte</strong>\n\t</h2>\n\n\t<Counter />\n</section>\n\n<style>\n\tsection {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: center;\n\t\talign-items: center;\n\t\tflex: 0.6;\n\t}\n\n\th1 {\n\t\twidth: 100%;\n\t}\n\n\t.welcome {\n\t\tdisplay: block;\n\t\tposition: relative;\n\t\twidth: 100%;\n\t\theight: 0;\n\t\tpadding: 0 0 calc(100% * 495 / 2048) 0;\n\t}\n\n\t.welcome-image {\n\t\tposition: absolute;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\ttop: 0;\n\t\tdisplay: block;\n\t}\n</style>\n"
|
|
13
13
|
},
|
|
14
14
|
{
|
|
15
15
|
"name": "src/routes/+page.ts",
|
|
@@ -12,11 +12,11 @@
|
|
|
12
12
|
"devDependencies": {
|
|
13
13
|
"@fontsource/fira-mono": "^5.2.7",
|
|
14
14
|
"@neoconfetti/svelte": "^2.2.2",
|
|
15
|
-
"@sveltejs/adapter-auto": "^8.0.0
|
|
16
|
-
"@sveltejs/kit": "^3.0.0
|
|
15
|
+
"@sveltejs/adapter-auto": "^8.0.0",
|
|
16
|
+
"@sveltejs/kit": "^3.0.0",
|
|
17
17
|
"@sveltejs/vite-plugin-svelte": "^7.2.0",
|
|
18
18
|
"svelte": "^5.56.7",
|
|
19
|
-
"vite": "^8.
|
|
19
|
+
"vite": "^8.3.0"
|
|
20
20
|
},
|
|
21
21
|
"imports": {
|
|
22
22
|
"#lib": "./src/lib/index.js",
|
|
@@ -23,14 +23,14 @@
|
|
|
23
23
|
"svelte": "^5.0.0"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@sveltejs/adapter-auto": "^8.0.0
|
|
27
|
-
"@sveltejs/kit": "^3.0.0
|
|
26
|
+
"@sveltejs/adapter-auto": "^8.0.0",
|
|
27
|
+
"@sveltejs/kit": "^3.0.0",
|
|
28
28
|
"@sveltejs/package": "^2.5.8",
|
|
29
29
|
"@sveltejs/vite-plugin-svelte": "^7.2.0",
|
|
30
30
|
"publint": "^0.3.21",
|
|
31
31
|
"svelte": "^5.56.7",
|
|
32
32
|
"typescript": "^6.0.3",
|
|
33
|
-
"vite": "^8.
|
|
33
|
+
"vite": "^8.3.0"
|
|
34
34
|
},
|
|
35
35
|
"keywords": ["svelte"],
|
|
36
36
|
"imports": {
|
|
@@ -10,11 +10,11 @@
|
|
|
10
10
|
"prepare": "svelte-kit sync || echo ''"
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"@sveltejs/adapter-auto": "^8.0.0
|
|
14
|
-
"@sveltejs/kit": "^3.0.0
|
|
13
|
+
"@sveltejs/adapter-auto": "^8.0.0",
|
|
14
|
+
"@sveltejs/kit": "^3.0.0",
|
|
15
15
|
"@sveltejs/vite-plugin-svelte": "^7.2.0",
|
|
16
16
|
"svelte": "^5.56.7",
|
|
17
|
-
"vite": "^8.
|
|
17
|
+
"vite": "^8.3.0"
|
|
18
18
|
},
|
|
19
19
|
"imports": {
|
|
20
20
|
"#lib": "./src/lib/index.js",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sv",
|
|
3
|
-
"version": "1.0.0
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "A command line interface (CLI) for creating and maintaining Svelte applications",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"create",
|
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
"url": "git+https://github.com/sveltejs/cli.git",
|
|
20
20
|
"directory": "packages/sv"
|
|
21
21
|
},
|
|
22
|
-
"bin": "./dist/bin.mjs",
|
|
23
22
|
"files": [
|
|
24
23
|
"dist"
|
|
25
24
|
],
|
|
@@ -35,7 +34,8 @@
|
|
|
35
34
|
}
|
|
36
35
|
},
|
|
37
36
|
"dependencies": {
|
|
38
|
-
"@sveltejs/sv-utils": "1.0.0
|
|
37
|
+
"@sveltejs/sv-utils": "1.0.0",
|
|
38
|
+
"node": "runtime:^22.18.0"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@clack/prompts": "1.5.0",
|
|
@@ -52,8 +52,19 @@
|
|
|
52
52
|
"tinyexec": "^1.2.4",
|
|
53
53
|
"valibot": "^1.4.1"
|
|
54
54
|
},
|
|
55
|
+
"engines": {
|
|
56
|
+
"runtime": {
|
|
57
|
+
"name": "node",
|
|
58
|
+
"version": "^22.18.0",
|
|
59
|
+
"onFail": "download"
|
|
60
|
+
}
|
|
61
|
+
},
|
|
55
62
|
"scripts": {
|
|
56
63
|
"check": "tsgo",
|
|
64
|
+
"update-kit-template-railway": "./src/create/scripts/update-kit-template-railway.sh",
|
|
57
65
|
"update-template-repo": "./src/create/scripts/update-template-repo.sh"
|
|
66
|
+
},
|
|
67
|
+
"bin": {
|
|
68
|
+
"sv": "./dist/bin.mjs"
|
|
58
69
|
}
|
|
59
70
|
}
|
|
Binary file
|