From 5f43222bde9d459ba4d7018c21c5a75cba441165 Mon Sep 17 00:00:00 2001 From: luo2430 Date: Thu, 19 Mar 2026 16:39:04 +0800 Subject: [PATCH] feat(oxlint): Modified `configuration_schema.json`,enhance `DummyRule` type to support `AllowWarnDeny | [AllowWarnDeny, ...unknown[]]` --- apps/oxlint/src-js/package/config.generated.ts | 2 +- npm/oxlint/configuration_schema.json | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/apps/oxlint/src-js/package/config.generated.ts b/apps/oxlint/src-js/package/config.generated.ts index 814e87f639f54..e77f25ed6312f 100644 --- a/apps/oxlint/src-js/package/config.generated.ts +++ b/apps/oxlint/src-js/package/config.generated.ts @@ -57,7 +57,7 @@ export type LintPluginOptionsSchema = | "node" | "vue"; export type LintPlugins = LintPluginOptionsSchema[]; -export type DummyRule = AllowWarnDeny | unknown[]; +export type DummyRule = AllowWarnDeny | [AllowWarnDeny, ...unknown[]]; export type OxlintOverrides = OxlintOverride[]; export type TagNamePreference = | string diff --git a/npm/oxlint/configuration_schema.json b/npm/oxlint/configuration_schema.json index c3a8939d967f2..791ee4ce79afe 100644 --- a/npm/oxlint/configuration_schema.json +++ b/npm/oxlint/configuration_schema.json @@ -224,7 +224,13 @@ }, { "type": "array", - "items": true + "items": [ + { + "$ref": "#/definitions/AllowWarnDeny" + } + ], + "minItems": 1, + "additionalItems": true } ] },