import { Awaitable, TypedFlatConfigItem } from "./types.mjs"; //#region src/utils.d.ts declare const parserPlain: { meta: { name: string; }; parseForESLint: (code: string) => { ast: { body: never[]; comments: never[]; loc: { end: number; start: number; }; range: number[]; tokens: never[]; type: string; }; scopeManager: null; services: { isPlain: boolean; }; visitorKeys: { Program: never[]; }; }; }; /** * Combine array and non-array configs into a single array. */ declare function combine(...configs: Awaitable[]): Promise; /** * Rename plugin prefixes in a rule object. * Accepts a map of prefixes to rename. * * @example * ```ts * import { renameRules } from '@mastondzn/eslint' * * export default [{ * rules: renameRules( * { * '@typescript-eslint/indent': 'error' * }, * { '@typescript-eslint': 'ts' } * ) * }] * ``` */ declare function renameRules(rules: Record, map: Record): Record; /** * Rename plugin names a flat configs array * * @example * ```ts * import { renamePluginInConfigs } from '@mastondzn/eslint' * import someConfigs from './some-configs' * * export default renamePluginInConfigs(someConfigs, { * '@typescript-eslint': 'ts', * 'import-x': 'import', * }) * ``` */ declare function renamePluginInConfigs(configs: TypedFlatConfigItem[], map: Record): TypedFlatConfigItem[]; declare function toArray(value: T | T[]): T[]; declare function interopDefault(m: Awaitable): Promise; declare function isPackageInScope(name: string): boolean; declare function ensurePackages(packages: (string | undefined)[]): Promise; declare function isInEditorEnv(): boolean; declare function isInGitHooksOrLintStaged(): boolean; //#endregion export { combine, ensurePackages, interopDefault, isInEditorEnv, isInGitHooksOrLintStaged, isPackageInScope, parserPlain, renamePluginInConfigs, renameRules, toArray };