UNPKG

eslint-plugin-better-tailwindcss

Version:

auto-wraps tailwind classes after a certain print width or class count into multiple lines to improve readability.

426 lines 20.1 kB
export declare const noDuplicateClasses: { category: "stylistic"; messages: { readonly duplicate: "Duplicate classname: \"{{ className }}\"."; } | undefined; name: "no-duplicate-classes"; readonly options: { cwd?: string | undefined; rootFontSize?: number | undefined; detectComponentClasses: boolean; tsconfig?: string | undefined; tailwindConfig?: string | undefined; messageStyle: "visual" | "compact" | "raw"; entryPoint?: string | undefined; tags?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; variables?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; attributes?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; callees?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; selectors: ({ callTarget?: number | "all" | "first" | "last" | undefined; kind: import("../types/rule.js").SelectorKind.Callee; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; path?: string | undefined; targetArgument?: number | "all" | "first" | "last" | undefined; targetCall?: number | "all" | "first" | "last" | undefined; } | { callTarget?: number | "all" | "first" | "last" | undefined; kind: import("../types/rule.js").SelectorKind.Callee; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name?: string | undefined; path: string; targetArgument?: number | "all" | "first" | "last" | undefined; targetCall?: number | "all" | "first" | "last" | undefined; } | { kind: import("../types/rule.js").SelectorKind.Tag; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; path?: string | undefined; } | { kind: import("../types/rule.js").SelectorKind.Tag; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name?: string | undefined; path: string; } | { kind: import("../types/rule.js").SelectorKind.Attribute; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; } | { kind: import("../types/rule.js").SelectorKind.Variable; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; })[]; } & { [x: string]: unknown; }; recommended: true; rule: { create: (ctx: import("node_modules/@eslint/core/dist/cjs/types.cjs").RuleContext<{ LangOptions: import("eslint").Linter.LanguageOptions; Code: import("eslint").SourceCode; RuleOptions: [Required<{ cwd?: string | undefined; rootFontSize?: number | undefined; detectComponentClasses: boolean; tsconfig?: string | undefined; tailwindConfig?: string | undefined; messageStyle: "visual" | "compact" | "raw"; entryPoint?: string | undefined; tags?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; variables?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; attributes?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; callees?: (string | [string, ({ match: import("../types/rule.js").MatcherType.String; } | { match: import("../types/rule.js").MatcherType.ObjectKey; pathPattern?: string | undefined; } | { match: import("../types/rule.js").MatcherType.ObjectValue; pathPattern?: string | undefined; })[]])[] | undefined; selectors: ({ callTarget?: number | "all" | "first" | "last" | undefined; kind: import("../types/rule.js").SelectorKind.Callee; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; path?: string | undefined; targetArgument?: number | "all" | "first" | "last" | undefined; targetCall?: number | "all" | "first" | "last" | undefined; } | { callTarget?: number | "all" | "first" | "last" | undefined; kind: import("../types/rule.js").SelectorKind.Callee; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name?: string | undefined; path: string; targetArgument?: number | "all" | "first" | "last" | undefined; targetCall?: number | "all" | "first" | "last" | undefined; } | { kind: import("../types/rule.js").SelectorKind.Tag; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; path?: string | undefined; } | { kind: import("../types/rule.js").SelectorKind.Tag; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name?: string | undefined; path: string; } | { kind: import("../types/rule.js").SelectorKind.Attribute; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; } | { kind: import("../types/rule.js").SelectorKind.Variable; match?: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; } | { match: ({ type: import("../types/rule.js").MatcherType.String; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectKey; } | { path?: string | undefined; type: import("../types/rule.js").MatcherType.ObjectValue; })[]; type: import("../types/rule.js").MatcherType.AnonymousFunctionReturn; })[] | undefined; name: string; })[]; } & { [x: string]: unknown; }>]; Node: import("eslint").JSSyntaxElement; MessageIds: "duplicate"; }>) => import("eslint").Rule.RuleListener; meta: { messages?: { readonly duplicate: "Duplicate classname: \"{{ className }}\"."; }; docs: { description: string; recommended: boolean; url: string; }; fixable: "code" | undefined; schema: { additionalProperties: false; properties: Record<string, boolean | import("@valibot/to-json-schema").JsonSchema> | undefined; type: "object"; }[]; type: "problem" | "layout"; }; }; }; //# sourceMappingURL=no-duplicate-classes.d.ts.map