sv 1.2.0 → 1.4.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.
Files changed (30) hide show
  1. package/dist/{shared.json → addons/ai-tools.json} +18 -199
  2. package/dist/{addons-Ih-Pmrow.mjs → addons-B9USH0bk.mjs} +101 -26
  3. package/dist/bin.mjs +46 -29
  4. package/dist/{engine-0i6PA_0L.mjs → engine-B1nZjPzd.mjs} +7 -61
  5. package/dist/playground/PlaygroundLayout.svelte +218 -0
  6. package/dist/src/index.d.mts +5 -4
  7. package/dist/src/index.mjs +2 -2
  8. package/dist/src/testing.mjs +1 -1
  9. package/dist/templates/addon/assets/CONTRIBUTING.md +48 -0
  10. package/dist/templates/addon/assets/README.md +29 -0
  11. package/dist/templates/addon/files.types=checkjs.json +10 -1
  12. package/dist/templates/addon/files.types=none.json +10 -1
  13. package/dist/templates/addon/files.types=typescript.json +10 -1
  14. package/dist/templates/addon/package.json +22 -16
  15. package/dist/templates/demo/assets/README.md +49 -0
  16. package/dist/templates/demo/files.types=checkjs.json +12 -0
  17. package/dist/templates/demo/files.types=none.json +12 -0
  18. package/dist/templates/demo/files.types=typescript.json +12 -0
  19. package/dist/templates/demo/package.json +10 -6
  20. package/dist/templates/library/assets/README.md +72 -0
  21. package/dist/templates/library/files.types=checkjs.json +12 -0
  22. package/dist/templates/library/files.types=none.json +12 -0
  23. package/dist/templates/library/files.types=typescript.json +12 -0
  24. package/dist/templates/library/package.json +28 -17
  25. package/dist/templates/minimal/assets/README.md +49 -0
  26. package/dist/templates/minimal/files.types=checkjs.json +12 -0
  27. package/dist/templates/minimal/files.types=none.json +12 -0
  28. package/dist/templates/minimal/files.types=typescript.json +12 -0
  29. package/dist/templates/minimal/package.json +10 -6
  30. package/package.json +2 -4
@@ -0,0 +1,218 @@
1
+ <script lang="ts">
2
+ import favicon from '#lib/assets/favicon.svg';
3
+
4
+ let { children } = $props();
5
+
6
+ const title = '$sv-title-$sv';
7
+ const href = '$sv-url-$sv';
8
+
9
+ let prefersDark = $state(true);
10
+ let isDark = $state(true);
11
+
12
+ function switchTheme() {
13
+ const value = isDark ? 'light' : 'dark';
14
+
15
+ isDark = value === 'dark';
16
+ localStorage.setItem('sv:theme', isDark === prefersDark ? 'system' : value);
17
+ }
18
+
19
+ $effect(() => {
20
+ document.documentElement.classList.remove('light', 'dark');
21
+ prefersDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
22
+
23
+ const theme = localStorage.getItem('sv:theme');
24
+
25
+ isDark = !theme ? prefersDark : theme === 'dark' || (theme === 'system' && prefersDark);
26
+ document.documentElement.classList.add(isDark ? 'dark' : 'light');
27
+ });
28
+ </script>
29
+
30
+ <svelte:head>
31
+ <title>--from-playground {title}</title>
32
+ <script>
33
+ {
34
+ const theme = localStorage.getItem('sv:theme');
35
+
36
+ document.documentElement.classList.add(
37
+ !theme || theme === 'system'
38
+ ? window.matchMedia('(prefers-color-scheme: dark)').matches
39
+ ? 'dark'
40
+ : 'light'
41
+ : theme
42
+ );
43
+ }
44
+ </script>
45
+ </svelte:head>
46
+
47
+ <div class="layout">
48
+ <nav class="navbar">
49
+ <div class="nav-left">
50
+ <a href="/" class="svelte-icon">
51
+ <img src={favicon} alt="Svelte" width="32" height="32" />
52
+ </a>
53
+ <p class="title">{title}</p>
54
+ </div>
55
+ <div class="nav-right">
56
+ <a {href} class="raised" target="_blank" rel="noopener noreferrer">
57
+ --to-playground
58
+ <span aria-hidden="true" style="margin-left:0.25em;"> ↗</span>
59
+ </a>
60
+ <button class="raised theme-toggle" onclick={switchTheme} aria-label="Toggle theme">
61
+ <span class="icon"></span>
62
+ </button>
63
+ </div>
64
+ </nav>
65
+
66
+ <main class="content">
67
+ {@render children()}
68
+ </main>
69
+ </div>
70
+
71
+ <style>
72
+ :global(body) {
73
+ margin: 0;
74
+ }
75
+
76
+ :global(html) {
77
+ margin: 0;
78
+ --bg-1: hsl(0, 0%, 100%);
79
+ --bg-2: hsl(206, 20%, 90%);
80
+ --bg-3: hsl(206, 20%, 80%);
81
+ --navbar-bg: #fff;
82
+ --fg-1: hsl(0, 0%, 13%);
83
+ --fg-2: hsl(0, 0%, 50%);
84
+ --fg-3: hsl(0, 0%, 60%);
85
+ --link: hsl(208, 77%, 47%);
86
+ --border-radius: 4px;
87
+ --font:
88
+ -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans',
89
+ 'Helvetica Neue', sans-serif;
90
+ color-scheme: light;
91
+ background: var(--bg-1);
92
+ color: var(--fg-1);
93
+ font-family: var(--font);
94
+ line-height: 1.5;
95
+ height: calc(100vh - 2rem);
96
+ accent-color: var(--link) !important;
97
+ min-height: 100vh;
98
+ background-color: var(--bg-1);
99
+ }
100
+
101
+ :global(html.dark) {
102
+ color-scheme: dark;
103
+ --bg-1: hsl(0, 0%, 18%);
104
+ --bg-2: hsl(0, 0%, 30%);
105
+ --bg-3: hsl(0, 0%, 40%);
106
+ --navbar-bg: hsl(220, 14%, 16%);
107
+ --fg-1: hsl(0, 0%, 75%);
108
+ --fg-2: hsl(0, 0%, 40%);
109
+ --fg-3: hsl(0, 0%, 30%);
110
+ --link: hsl(206, 96%, 72%);
111
+ }
112
+
113
+ .navbar {
114
+ color: var(--fg-1);
115
+ display: flex;
116
+ justify-content: space-between;
117
+ align-items: center;
118
+ padding: 0em 2.5rem;
119
+ height: 3.7rem;
120
+ background-color: var(--navbar-bg);
121
+ box-shadow:
122
+ 0 2px 8px 0 rgba(0, 0, 0, 0.08),
123
+ 0 1.5px 4px 0 rgba(0, 0, 0, 0.04);
124
+ }
125
+
126
+ .nav-left {
127
+ display: flex;
128
+ align-items: center;
129
+ gap: 0.5rem;
130
+ }
131
+
132
+ .svelte-icon {
133
+ display: flex;
134
+ align-items: center;
135
+ text-decoration: none;
136
+ transition: opacity 0.2s ease;
137
+ }
138
+
139
+ .svelte-icon:hover {
140
+ opacity: 0.8;
141
+ }
142
+
143
+ .title {
144
+ font-size: 1.5rem;
145
+ font-weight: 400;
146
+ margin: 0;
147
+ }
148
+
149
+ .nav-right {
150
+ display: flex;
151
+ align-items: center;
152
+ gap: 1rem;
153
+ }
154
+
155
+ .raised {
156
+ background: var(--navbar-bg);
157
+ border-left: 0.5px solid var(--fg-3);
158
+ border-top: 0.5px solid var(--fg-3);
159
+ border-bottom: none;
160
+ border-right: none;
161
+ border-radius: var(--border-radius);
162
+ color: var(--fg-1);
163
+ cursor: pointer;
164
+ transition: all 0.2s ease;
165
+ box-shadow:
166
+ 0 2px 4px rgba(0, 0, 0, 0.1),
167
+ 0 1px 2px rgba(0, 0, 0, 0.06);
168
+ text-decoration: none;
169
+ font-weight: 500;
170
+ padding: 0.25rem 0.75rem;
171
+ font-size: 0.8rem;
172
+ }
173
+
174
+ .raised:hover {
175
+ border-left-color: var(--fg-2);
176
+ border-top-color: var(--fg-2);
177
+ box-shadow:
178
+ 0 4px 8px rgba(0, 0, 0, 0.15),
179
+ 0 2px 4px rgba(0, 0, 0, 0.1);
180
+ transform: translate(-1px, -1px);
181
+ }
182
+
183
+ .content {
184
+ padding: 1rem;
185
+ color: var(--fg-1);
186
+ }
187
+
188
+ .theme-toggle {
189
+ display: flex;
190
+ align-items: center;
191
+ justify-content: center;
192
+ width: 1.8rem;
193
+ height: 1.8rem;
194
+ padding: 0;
195
+ min-width: 2rem;
196
+ }
197
+
198
+ .icon {
199
+ display: inline-block;
200
+ width: 1.5rem;
201
+ height: 1.5rem;
202
+ -webkit-mask-size: 1.5rem;
203
+ mask-size: 1.5rem;
204
+ -webkit-mask-repeat: no-repeat;
205
+ mask-repeat: no-repeat;
206
+ -webkit-mask-position: center;
207
+ mask-position: center;
208
+ background-color: var(--fg-1);
209
+ }
210
+
211
+ .icon {
212
+ mask-image: url('data:image/svg+xml,%3csvg%20xmlns="http://www.w3.org/2000/svg"%20viewBox="0%200%2024%2024"%3e%3cpath%20fill="%23666"%20d="M12%2021q-3.775%200-6.388-2.613T3%2012q0-3.45%202.25-5.988T11%203.05q.625-.075.975.45t-.025%201.1q-.425.65-.638%201.375T11.1%207.5q0%202.25%201.575%203.825T16.5%2012.9q.775%200%201.538-.225t1.362-.625q.525-.35%201.075-.037t.475.987q-.35%203.45-2.937%205.725T12%2021Zm0-2q2.2%200%203.95-1.213t2.55-3.162q-.5.125-1%20.2t-1%20.075q-3.075%200-5.238-2.163T9.1%207.5q0-.5.075-1t.2-1q-1.95.8-3.163%202.55T5%2012q0%202.9%202.05%204.95T12%2019Zm-.25-6.75Z"/%3e%3c/svg%3e');
213
+ }
214
+
215
+ :global(html.dark) .icon {
216
+ mask-image: url("data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23d4d4d4'%20d='M12%2019a1%201%200%200%201%20.993.883L13%2020v1a1%201%200%200%201-1.993.117L11%2021v-1a1%201%200%200%201%201-1zm6.313-2.09.094.083.7.7a1%201%200%200%201-1.32%201.497l-.094-.083-.7-.7a1%201%200%200%201%201.218-1.567l.102.07zm-11.306.083a1%201%200%200%201%20.083%201.32l-.083.094-.7.7a1%201%200%200%201-1.497-1.32l.083-.094.7-.7a1%201%200%200%201%201.414%200zM4%2011a1%201%200%200%201%20.117%201.993L4%2013H3a1%201%200%200%201-.117-1.993L3%2011h1zm17%200a1%201%200%200%201%20.117%201.993L21%2013h-1a1%201%200%200%201-.117-1.993L20%2011h1zM6.213%204.81l.094.083.7.7a1%201%200%200%201-1.32%201.497l-.094-.083-.7-.7A1%201%200%200%201%206.11%204.74l.102.07zm12.894.083a1%201%200%200%201%20.083%201.32l-.083.094-.7.7a1%201%200%200%201-1.497-1.32l.083-.094.7-.7a1%201%200%200%201%201.414%200zM12%202a1%201%200%200%201%20.993.883L13%203v1a1%201%200%200%201-1.993.117L11%204V3a1%201%200%200%201%201-1zm0%205a5%205%200%201%201-4.995%205.217L7%2012l.005-.217A5%205%200%200%201%2012%207z'/%3e%3c/svg%3e");
217
+ }
218
+ </style>
@@ -1,9 +1,8 @@
1
1
  import { A as SelectQuestion, C as BaseQuestion, D as OptionDefinition, E as NumberQuestion, M as ADDON_IDS, O as OptionValues, S as AddonOptions, T as MultiSelectQuestion, _ as SvApi, a as Addon, b as Workspace, c as AddonReference, d as ConditionDefinition, f as ConfiguredAddon, g as SetupResult, h as PreparedAddon, i as add, j as StringQuestion, k as Question, l as AddonResult, m as OptionBuilder, n as InstallOptions, o as AddonDefinition, p as LoadedAddon, r as OptionMap, s as AddonInput, t as AddonMap, u as AddonSource, v as defineAddon, w as BooleanQuestion, x as WorkspaceOptions, y as defineAddonOptions } from "../engine-fNvU_-IL.mjs";
2
2
  //#region src/create/index.d.ts
3
- type TemplateType = (typeof templateTypes)[number];
4
- type LanguageType = (typeof languageTypes)[number];
5
- declare const templateTypes: readonly ["minimal", "demo", "library", "addon", "svelte"];
6
- declare const languageTypes: readonly ["typescript", "checkjs", "none"];
3
+ declare const publicTemplateTypes: readonly ["minimal", "demo", "library", "addon"];
4
+ type TemplateType = (typeof publicTemplateTypes)[number] | "svelte";
5
+ type LanguageType = "typescript" | "checkjs" | "none";
7
6
  type Options = {
8
7
  cwd: string;
9
8
  name: string;
@@ -18,6 +17,8 @@ type AiToolsOptions = {
18
17
  delivery: "plugin" | "tools";
19
18
  tools: string[];
20
19
  mcpSetup: "local" | "remote";
20
+ agentsMd: boolean;
21
+ optInSkills: string[];
21
22
  };
22
23
  //#endregion
23
24
  //#region src/addons/better-auth.d.ts
@@ -1,3 +1,3 @@
1
- import { C as create, _ as defineAddon, t as add, v as defineAddonOptions } from "../engine-0i6PA_0L.mjs";
2
- import { n as officialAddons } from "../addons-Ih-Pmrow.mjs";
1
+ import { C as create, _ as defineAddon, t as add, v as defineAddonOptions } from "../engine-B1nZjPzd.mjs";
2
+ import { n as officialAddons } from "../addons-B9USH0bk.mjs";
3
3
  export { add, create, defineAddon, defineAddonOptions, officialAddons };
@@ -1,4 +1,4 @@
1
- import { C as create, Ct as __require, S as execSync, St as __commonJSMin, l as addAllowBuildsIfPnpm, t as add, wt as __toESM, x as exec } from "../engine-0i6PA_0L.mjs";
1
+ import { C as create, Ct as __toESM, S as execSync, St as __require, l as addAllowBuildsIfPnpm, t as add, x as exec, xt as __commonJSMin } from "../engine-B1nZjPzd.mjs";
2
2
  import fs from "node:fs";
3
3
  import path from "node:path";
4
4
  import V from "node:process";
@@ -0,0 +1,48 @@
1
+ # Contributing Guide
2
+
3
+ Cheatsheet: [All official add-ons source code](https://github.com/sveltejs/cli/tree/main/packages/sv/src/addons)
4
+
5
+ ---
6
+
7
+ Some convenient scripts are provided to help develop the add-on.
8
+
9
+ ```sh
10
+ ## create a new minimal project in the `demo` directory
11
+ npm run demo-create
12
+
13
+ ## add your current add-on to the demo project
14
+ npm run demo-add
15
+
16
+ ## run the tests
17
+ npm run test
18
+ ```
19
+
20
+ ## Key things to note
21
+
22
+ Your `add-on` should:
23
+
24
+ - export a function that returns a `defineAddon` object.
25
+ - have a `package.json` with an `exports` field that points to the main entry point of the add-on.
26
+
27
+ ## Building
28
+
29
+ Your add-on is bundled with [tsdown](https://tsdown.dev/) into a single file in `dist/`. This bundles everything except `sv` (which is a peer dependency provided at runtime).
30
+
31
+ ```sh
32
+ npm run build
33
+ ```
34
+
35
+ ## Publishing
36
+
37
+ When you're ready to publish your add-on to npm:
38
+
39
+ ```sh
40
+ npm login
41
+ npm publish
42
+ ```
43
+
44
+ > `prepublishOnly` will automatically run the build before publishing.
45
+
46
+ ## Things to be aware of
47
+
48
+ Community add-ons must have `sv` as a `peerDependency`. Any `dependencies` declared in `package.json` will not be available at runtime. Everything else (including `@sveltejs/sv-utils`) is bundled at build time by tsdown.
@@ -0,0 +1,29 @@
1
+ # [sv](https://svelte.dev/docs/cli/overview) community add-on: [$SV-NAME-TODO$](https://github.com/$SV-NAME-TODO$)
2
+
3
+ > [!IMPORTANT]
4
+ > Svelte maintainers have not reviewed community add-ons for malicious code! Use at your discretion.
5
+
6
+ ## Usage
7
+
8
+ To install the add-on, run:
9
+
10
+ ```shell
11
+ npx sv add $SV-PROTOCOL-NAME-TODO$
12
+ ```
13
+
14
+ ## What you get [TO BE FILLED...]
15
+
16
+ - A super cool stuff
17
+ - Another one!
18
+
19
+ ## Options [TO BE FILLED...]
20
+
21
+ ### `who`
22
+
23
+ The name of the person to say hello to.
24
+
25
+ Default: `you`
26
+
27
+ ```shell
28
+ npx sv add $SV-PROTOCOL-NAME-TODO$="who:your-name"
29
+ ```
@@ -1 +1,10 @@
1
- []
1
+ [
2
+ {
3
+ "name": "jsconfig.json",
4
+ "contents": "{\n\t\"compilerOptions\": {\n\t\t\"strict\": true,\n\t\t\"skipLibCheck\": true,\n\t\t\"checkJs\": true,\n\t\t\"module\": \"NodeNext\",\n\t\t\"moduleResolution\": \"NodeNext\"\n\t}\n}\n"
5
+ },
6
+ {
7
+ "name": "package.json",
8
+ "contents": "{\n\t\"name\": \"$SV-NAME-TODO$\",\n\t\"version\": \"0.0.1\",\n\t\"description\": \"sv add-on for $SV-NAME-TODO$\",\n\t\"keywords\": [\n\t\t\"sv-add\",\n\t\t\"svelte\",\n\t\t\"sveltekit\"\n\t],\n\t\"license\": \"MIT\",\n\t\"files\": [\n\t\t\"dist\"\n\t],\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"default\": \"./dist/index.mjs\"\n\t\t}\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t},\n\t\"scripts\": {\n\t\t\"demo-create\": \"sv create demo --types ts --template minimal --no-add-ons --no-install\",\n\t\t\"demo-add\": \"pnpm build && sv add file:../ --cwd demo --no-git-check --no-install\",\n\t\t\"demo-add:ci\": \"pnpm build && sv add file:../=who:you --cwd demo --no-git-check --no-download-check --no-install\",\n\t\t\"build\": \"tsdown\",\n\t\t\"prepublishOnly\": \"npm run build\",\n\t\t\"test\": \"vitest run\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@playwright/test\": \"^1.60.0\",\n\t\t\"@sveltejs/sv-utils\": \"^1.1.1\",\n\t\t\"@types/node\": \"^25.9.1\",\n\t\t\"sv\": \"^1.4.0\",\n\t\t\"tsdown\": \"^0.22.1\",\n\t\t\"vitest\": \"^4.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"sv\": \"^1.4.0\"\n\t}\n}\n"
9
+ }
10
+ ]
@@ -1 +1,10 @@
1
- []
1
+ [
2
+ {
3
+ "name": "jsconfig.json",
4
+ "contents": "{\n\t\"compilerOptions\": {\n\t\t\"strict\": true,\n\t\t\"skipLibCheck\": true,\n\t\t\"checkJs\": true,\n\t\t\"module\": \"NodeNext\",\n\t\t\"moduleResolution\": \"NodeNext\"\n\t}\n}\n"
5
+ },
6
+ {
7
+ "name": "package.json",
8
+ "contents": "{\n\t\"name\": \"$SV-NAME-TODO$\",\n\t\"version\": \"0.0.1\",\n\t\"description\": \"sv add-on for $SV-NAME-TODO$\",\n\t\"keywords\": [\n\t\t\"sv-add\",\n\t\t\"svelte\",\n\t\t\"sveltekit\"\n\t],\n\t\"license\": \"MIT\",\n\t\"files\": [\n\t\t\"dist\"\n\t],\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"default\": \"./dist/index.mjs\"\n\t\t}\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t},\n\t\"scripts\": {\n\t\t\"demo-create\": \"sv create demo --types ts --template minimal --no-add-ons --no-install\",\n\t\t\"demo-add\": \"pnpm build && sv add file:../ --cwd demo --no-git-check --no-install\",\n\t\t\"demo-add:ci\": \"pnpm build && sv add file:../=who:you --cwd demo --no-git-check --no-download-check --no-install\",\n\t\t\"build\": \"tsdown\",\n\t\t\"prepublishOnly\": \"npm run build\",\n\t\t\"test\": \"vitest run\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@playwright/test\": \"^1.60.0\",\n\t\t\"@sveltejs/sv-utils\": \"^1.1.1\",\n\t\t\"@types/node\": \"^25.9.1\",\n\t\t\"sv\": \"^1.4.0\",\n\t\t\"tsdown\": \"^0.22.1\",\n\t\t\"vitest\": \"^4.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"sv\": \"^1.4.0\"\n\t}\n}\n"
9
+ }
10
+ ]
@@ -1 +1,10 @@
1
- []
1
+ [
2
+ {
3
+ "name": "tsconfig.json",
4
+ "contents": "{\n\t\"compilerOptions\": {\n\t\t\"strict\": true,\n\t\t\"skipLibCheck\": true,\n\t\t\"checkJs\": true,\n\t\t\"module\": \"NodeNext\",\n\t\t\"moduleResolution\": \"NodeNext\"\n\t}\n}\n"
5
+ },
6
+ {
7
+ "name": "package.json",
8
+ "contents": "{\n\t\"name\": \"$SV-NAME-TODO$\",\n\t\"version\": \"0.0.1\",\n\t\"description\": \"sv add-on for $SV-NAME-TODO$\",\n\t\"keywords\": [\n\t\t\"sv-add\",\n\t\t\"svelte\",\n\t\t\"sveltekit\"\n\t],\n\t\"license\": \"MIT\",\n\t\"files\": [\n\t\t\"dist\"\n\t],\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"default\": \"./dist/index.mjs\"\n\t\t}\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t},\n\t\"scripts\": {\n\t\t\"demo-create\": \"sv create demo --types ts --template minimal --no-add-ons --no-install\",\n\t\t\"demo-add\": \"pnpm build && sv add file:../ --cwd demo --no-git-check --no-install\",\n\t\t\"demo-add:ci\": \"pnpm build && sv add file:../=who:you --cwd demo --no-git-check --no-download-check --no-install\",\n\t\t\"build\": \"tsdown\",\n\t\t\"prepublishOnly\": \"npm run build\",\n\t\t\"test\": \"vitest run\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@playwright/test\": \"^1.60.0\",\n\t\t\"@sveltejs/sv-utils\": \"^1.1.1\",\n\t\t\"@types/node\": \"^25.9.1\",\n\t\t\"sv\": \"^1.4.0\",\n\t\t\"tsdown\": \"^0.22.1\",\n\t\t\"vitest\": \"^4.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"sv\": \"^1.4.0\"\n\t}\n}\n"
9
+ }
10
+ ]
@@ -1,18 +1,17 @@
1
1
  {
2
2
  "name": "$SV-NAME-TODO$",
3
- "description": "sv add-on for $SV-NAME-TODO$",
4
3
  "version": "0.0.1",
5
- "type": "module",
4
+ "description": "sv add-on for $SV-NAME-TODO$",
5
+ "keywords": [
6
+ "sv-add",
7
+ "svelte",
8
+ "sveltekit"
9
+ ],
6
10
  "license": "MIT",
7
- "scripts": {
8
- "demo-create": "sv create demo --types ts --template minimal --no-add-ons --no-install",
9
- "demo-add": "pnpm build && sv add file:../ --cwd demo --no-git-check --no-install",
10
- "demo-add:ci": "pnpm build && sv add file:../=who:you --cwd demo --no-git-check --no-download-check --no-install",
11
- "build": "tsdown",
12
- "prepublishOnly": "npm run build",
13
- "test": "vitest run"
14
- },
15
- "files": ["dist"],
11
+ "files": [
12
+ "dist"
13
+ ],
14
+ "type": "module",
16
15
  "exports": {
17
16
  ".": {
18
17
  "default": "./dist/index.mjs"
@@ -21,16 +20,23 @@
21
20
  "publishConfig": {
22
21
  "access": "public"
23
22
  },
24
- "peerDependencies": {
25
- "sv": "^1.2.0"
23
+ "scripts": {
24
+ "demo-create": "sv create demo --types ts --template minimal --no-add-ons --no-install",
25
+ "demo-add": "pnpm build && sv add file:../ --cwd demo --no-git-check --no-install",
26
+ "demo-add:ci": "pnpm build && sv add file:../=who:you --cwd demo --no-git-check --no-download-check --no-install",
27
+ "build": "tsdown",
28
+ "prepublishOnly": "npm run build",
29
+ "test": "vitest run"
26
30
  },
27
31
  "devDependencies": {
28
- "sv": "^1.2.0",
29
- "@sveltejs/sv-utils": "^1.1.0",
30
32
  "@playwright/test": "^1.60.0",
33
+ "@sveltejs/sv-utils": "^1.1.1",
31
34
  "@types/node": "^25.9.1",
35
+ "sv": "^1.4.0",
32
36
  "tsdown": "^0.22.1",
33
37
  "vitest": "^4.1.8"
34
38
  },
35
- "keywords": ["sv-add", "svelte", "sveltekit"]
39
+ "peerDependencies": {
40
+ "sv": "^1.4.0"
41
+ }
36
42
  }
@@ -0,0 +1,49 @@
1
+ # sv
2
+
3
+ Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).
4
+
5
+ ## Creating a project
6
+
7
+ If you're seeing this, you've probably already done this step. Congrats!
8
+
9
+ ```sh
10
+ # create a new project
11
+ npx sv create my-app
12
+ ```
13
+
14
+ ## Adding features
15
+
16
+ Add features to your project with `sv add`:
17
+
18
+ ```sh
19
+ npx sv add
20
+ ```
21
+
22
+ For example, to add Tailwind CSS:
23
+
24
+ ```sh
25
+ npx sv add tailwindcss
26
+ ```
27
+
28
+ ## Developing
29
+
30
+ Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
31
+
32
+ ```sh
33
+ npm run dev
34
+
35
+ # or start the server and open the app in a new browser tab
36
+ npm run dev -- --open
37
+ ```
38
+
39
+ ## Building
40
+
41
+ To create a production version of your app:
42
+
43
+ ```sh
44
+ npm run build
45
+ ```
46
+
47
+ You can preview the production build with `npm run preview`.
48
+
49
+ > To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.