@noctcore/eslint-plugin-contracts 0.2.0 โ†’ 0.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.
package/README.md CHANGED
@@ -52,7 +52,10 @@ Legend: ๐Ÿ”ง = autofixable ยท ๐Ÿ’ค = ships inert / `off` in `recommended` (enabl
52
52
  | [`require-registered-keys`](./docs/rules/require-registered-keys.md) | Key/name argument of a configured sink API must be an imported constant, not a raw string. | | ๐Ÿ’ค |
53
53
  | [`env-var-schema-parity`](./docs/rules/env-var-schema-parity.md) | `process.env.FOO` / `import.meta.env.FOO` keys must be declared in a schema file. | | ๐Ÿ’ค |
54
54
  | [`require-schema-parse-at-boundary`](./docs/rules/require-schema-parse-at-boundary.md) | Ban `JSON.parse(...) as T` / `(await res.json()) as T`; parse boundary data at runtime. | | ๐Ÿ’ค |
55
+ | [`schema-enum-field-consistency`](./docs/rules/schema-enum-field-consistency.md) | A field that is an enum in one zod object schema must not be `z.string()` in another schema of the same module. | | |
56
+ | [`fetch-must-check-ok`](./docs/rules/fetch-must-check-ok.md) | A fetch response must be checked with `.ok` or a status comparison before `.json()` parses its body. | | |
57
+ | [`translation-key-exists`](./docs/rules/translation-key-exists.md) | A static i18next / react-i18next key (`t(...)`, `i18n.t(...)`, `<Trans i18nKey>`) must exist in the catalog of the namespace in scope. | | ๐Ÿ’ค |
55
58
 
56
- The ๐Ÿ’ค rules ship `off` in `recommended`: `require-registered-keys` and `env-var-schema-parity` do
57
- nothing until their `sinks` / `schema` options are set, and `require-schema-parse-at-boundary` is a
59
+ The ๐Ÿ’ค rules ship `off` in `recommended`: `require-registered-keys`, `env-var-schema-parity` and
60
+ `translation-key-exists` do nothing until their `sinks` / `schema` / `catalogs` options are set, and `require-schema-parse-at-boundary` is a
58
61
  conservative syntactic slice of a type-aware concern. Turn them on explicitly once configured.