@gost-kit/eslint-config-svelte 0.2.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/CHANGELOG.md CHANGED
@@ -1,5 +1,16 @@
1
1
  # @gost-kit/eslint-config-svelte
2
2
 
3
+ ## 0.2.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 9f59da3: Add the opt-in ready-boolean-condition rule for Svelte if/else-if conditions.
8
+ Accept ready boolean reads and literals, report computations/truthiness, and
9
+ require typed parser services with strictNullChecks for reads. The Svelte config
10
+ registers the rule off; projects select business/UI-Kit scopes explicitly.
11
+ - Updated dependencies [9f59da3]
12
+ - @gost-kit/eslint-plugin@0.2.0
13
+
3
14
  ## 0.2.0
4
15
 
5
16
  ### Minor Changes
package/README.md CHANGED
@@ -89,8 +89,12 @@ owns browser-event adaptation and may opt out through file overrides. This is
89
89
  not a blanket browser API detector, and there is no autofix. Consult the plugin
90
90
  inventory for supported aliases and scope limits.
91
91
 
92
- Boolean conditions (#18) and presentation computations in derived/template
93
- expressions (#19) remain separate work. Existing `$state.raw`
92
+ The bundled `gost/ready-boolean-condition` rule is off by default. Enable it for
93
+ business components to require ready boolean if/else-if conditions; strictNullChecks
94
+ and typed parser services are required for reads. Boolean literals are allowed;
95
+ comparisons, calls, nullable truthiness and dynamic keys are reported. UI-Kit
96
+ paths can override it off. The check does not prove presenter provenance and
97
+ has no autofix. Presentation computations outside conditions remain #19. Existing `$state.raw`
94
98
  shell bindings and feature selectors remain valid; the Svelte compiler/type
95
99
  checker still verifies compilation/accessibility.
96
100
 
package/RULES.md CHANGED
@@ -38,7 +38,7 @@ and `**/*.svelte.js` where the upstream rule supports the corresponding syntax.
38
38
 
39
39
  Not enabled: AS04 DOM/listener restrictions, AS05 SSR browser-global restrictions,
40
40
  AS06 prefer-svelte-reactivity, legacy recommended/experimental rules and SvelteKit
41
- routing rules. Prettier owns HTML/CSS formatting. Architecture checks #18–#19 remain separate outcomes.
41
+ routing rules. Prettier owns HTML/CSS formatting. Presentation computations outside conditions remain a separate outcome (#19).
42
42
 
43
43
  The bundled GOST plugin additionally enables `gost/require-feature-state-selector`
44
44
  at error for TypeScript component scripts and `.svelte.ts`. It checks public
@@ -59,3 +59,10 @@ exception and no autofix. See the plugin inventory for exact boundaries.
59
59
  GOST Dispatch calls and conditional intent selection in typed instance `on*`
60
60
  callbacks. Business/UI-Kit scopes use explicit consumer overrides. It requires
61
61
  type services and has no autofix; see the plugin inventory for limits.
62
+
63
+ `gost/ready-boolean-condition` is registered explicitly off. Opt in for business
64
+ components; boolean literals and ready boolean identifier/static member reads
65
+ are allowed. Computations, nonboolean/nullable/any/unknown/never conditions are
66
+ reported. Reads require type services and strictNullChecks; missing configuration
67
+ fails explicitly. JS/stateless template reads are checked when typed services are
68
+ available. There is no autofix or proof of presenter origin; see plugin inventory.
@@ -39,7 +39,10 @@ export const createSvelteConfig = async ({ tsconfigRootDir, }) => {
39
39
  name: 'gost-svelte/architecture',
40
40
  files: ['**/*.svelte', '**/*.svelte.ts'],
41
41
  plugins: { gost: plugin },
42
- rules: { 'gost/require-feature-state-selector': 'error' },
42
+ rules: {
43
+ 'gost/require-feature-state-selector': 'error',
44
+ 'gost/ready-boolean-condition': 'off',
45
+ },
43
46
  },
44
47
  {
45
48
  name: 'gost-svelte/selected-rules',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gost-kit/eslint-config-svelte",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "Shared Svelte 5 ESLint configuration with the GOST JavaScript and TypeScript baseline.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -50,7 +50,7 @@
50
50
  "eslint-plugin-svelte": "3.24.0",
51
51
  "svelte-eslint-parser": "1.10.1",
52
52
  "typescript-eslint": "8.72.1",
53
- "@gost-kit/eslint-plugin": "0.1.0"
53
+ "@gost-kit/eslint-plugin": "0.2.0"
54
54
  },
55
55
  "peerDependencies": {
56
56
  "eslint": "^10.14.0",