@thomaflette/eslint-plugin-solid-2 0.1.0 → 0.2.1
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 +8 -3
- package/dist/index.cjs +810 -468
- package/dist/index.d.cts +79 -63
- package/dist/index.d.mts +79 -63
- package/dist/index.mjs +810 -468
- package/docs/README.md +24 -0
- package/docs/adr/0001-only-false-positive-free-rules.md +65 -0
- package/docs/adr/0002-sound-component-detection.md +66 -0
- package/docs/adr/0003-require-solid-binding.md +50 -0
- package/docs/adr/0004-correctness-guard-not-migration-tool.md +48 -0
- package/docs/adr/0005-recommended-type-checked-config.md +27 -0
- package/docs/adr/0006-merge-leaf-owner-rules.md +42 -0
- package/docs/adr/0007-typescript-audience.md +35 -0
- package/docs/components-return-once.md +89 -0
- package/docs/dev-diagnostic-coverage.md +29 -0
- package/docs/jsx-no-duplicate-props.md +34 -0
- package/docs/no-destructure.md +92 -0
- package/docs/no-leaf-owner-operations.md +90 -0
- package/docs/no-owned-scope-writes.md +117 -0
- package/docs/no-reactive-read-after-await.md +87 -0
- package/docs/no-stale-props-alias.md +157 -0
- package/docs/no-untracked-read-in-effect-apply.md +97 -0
- package/docs/prefer-for.md +81 -0
- package/docs/prefer-show.md +59 -0
- package/docs/self-closing-comp.md +42 -0
- package/package.json +7 -5
package/README.md
CHANGED
|
@@ -23,7 +23,9 @@ import solid from "@thomaflette/eslint-plugin-solid-2";
|
|
|
23
23
|
export default [solid.configs.recommended];
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
-
For a TypeScript project, prefer the type-checked config. It adds cross-file component detection
|
|
26
|
+
For a TypeScript project, prefer the type-checked config. It adds cross-file component detection,
|
|
27
|
+
nominal accessor and re-exported Solid API recognition, and enables `prefer-for` only when the
|
|
28
|
+
receiver is proven to be an array:
|
|
27
29
|
|
|
28
30
|
```js
|
|
29
31
|
// eslint.config.js
|
|
@@ -55,13 +57,15 @@ The `flat/recommended` and `flat/recommended-type-checked` names are aliases for
|
|
|
55
57
|
| `no-leaf-owner-operations` | Invalid cleanup, flush, and child-owner work inside leaf owners. |
|
|
56
58
|
| `no-owned-scope-writes` | State writes and action calls from component or compute scopes. |
|
|
57
59
|
| `no-reactive-read-after-await` | Accessor reads after an `await` in a reactive computation. |
|
|
58
|
-
| `no-stale-props-alias` |
|
|
60
|
+
| `no-stale-props-alias` | Provable untracked reactive reads in components and control-flow function children. |
|
|
59
61
|
| `no-untracked-read-in-effect-apply` | Signal and store reads in an effect apply callback. |
|
|
60
62
|
| `prefer-for` | Uses `<For>` for reactive array rendering when type information proves `Array#map`. |
|
|
61
63
|
| `prefer-show` | Uses `<Show>` for idiomatic reactive JSX conditionals. |
|
|
62
64
|
| `self-closing-comp` | Keeps empty JSX elements consistently self-closing. |
|
|
63
65
|
|
|
64
|
-
Every rule has focused documentation in [docs](./docs).
|
|
66
|
+
Every rule has focused documentation in [docs](./docs). The
|
|
67
|
+
[dev-diagnostic coverage matrix](./docs/dev-diagnostic-coverage.md) records which Solid runtime
|
|
68
|
+
diagnostics are covered statically and which remain intentionally runtime-only.
|
|
65
69
|
|
|
66
70
|
## Design principles
|
|
67
71
|
|
|
@@ -80,6 +84,7 @@ vp install
|
|
|
80
84
|
vp check
|
|
81
85
|
vp test
|
|
82
86
|
vp run build
|
|
87
|
+
vp test bench
|
|
83
88
|
```
|
|
84
89
|
|
|
85
90
|
## License
|