@spences10/pi-svelte-guardrails 0.0.7 → 0.0.9
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 +20 -3
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
# @spences10/pi-svelte-guardrails
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
[](https://viteplus.dev)
|
|
4
|
+
[](https://vitest.dev)
|
|
5
|
+
[](https://www.npmjs.com/package/@spences10/pi-svelte-guardrails)
|
|
6
|
+
[](https://www.npmjs.com/package/@spences10/pi-svelte-guardrails)
|
|
7
|
+
|
|
8
|
+
Catch discouraged Svelte patterns before they land in your codebase.
|
|
9
|
+
`pi-svelte-guardrails` blocks common agent mistakes and points the
|
|
10
|
+
model toward current Svelte 5 practices while edits are still cheap to
|
|
11
|
+
fix.
|
|
6
12
|
|
|
7
13
|
By default, blocks `$effect` in `.svelte` `write`/`edit` tool calls
|
|
8
14
|
and bash writes, then tells the agent to prefer `$derived`, event
|
|
@@ -68,3 +74,14 @@ the pattern. The current default remains `block`.
|
|
|
68
74
|
When a tool result says a write was blocked, the target file was not
|
|
69
75
|
created or modified. Rewrite the change without `$effect` and run the
|
|
70
76
|
write/edit again before reporting success.
|
|
77
|
+
|
|
78
|
+
## Development
|
|
79
|
+
|
|
80
|
+
Package scripts build transitive workspace dependencies first, then
|
|
81
|
+
run local tools through Vite+ with `vp exec`.
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
pnpm --filter @spences10/pi-svelte-guardrails run check
|
|
85
|
+
pnpm --filter @spences10/pi-svelte-guardrails run test
|
|
86
|
+
pnpm --filter @spences10/pi-svelte-guardrails run build
|
|
87
|
+
```
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spences10/pi-svelte-guardrails",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"description": "Pi
|
|
3
|
+
"version": "0.0.9",
|
|
4
|
+
"description": "Svelte 5 guardrails for Pi that block discouraged agent-written patterns before they land in code",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"agent-guardrails",
|
|
7
7
|
"pi",
|
|
@@ -47,13 +47,13 @@
|
|
|
47
47
|
},
|
|
48
48
|
"scripts": {
|
|
49
49
|
"build": "pnpm --filter \"$npm_package_name^...\" run build:self && pnpm run build:self",
|
|
50
|
-
"build:self": "tsc -p tsconfig.build.json",
|
|
50
|
+
"build:self": "vp exec tsc -p tsconfig.build.json",
|
|
51
51
|
"check": "pnpm --filter \"$npm_package_name^...\" run build:self && pnpm run check:self",
|
|
52
|
-
"check:self": "tsc --noEmit -p tsconfig.json",
|
|
52
|
+
"check:self": "vp exec tsc --noEmit -p tsconfig.json",
|
|
53
53
|
"test": "pnpm --filter \"$npm_package_name^...\" run build:self && pnpm run test:self",
|
|
54
|
-
"test:self": "vitest run",
|
|
55
|
-
"test:watch": "vitest",
|
|
56
|
-
"coverage:self": "vitest run --coverage",
|
|
54
|
+
"test:self": "vp exec vitest run",
|
|
55
|
+
"test:watch": "vp exec vitest",
|
|
56
|
+
"coverage:self": "vp exec vitest run --coverage",
|
|
57
57
|
"coverage": "pnpm --filter \"$npm_package_name^...\" run build:self && pnpm run coverage:self"
|
|
58
58
|
}
|
|
59
59
|
}
|