import type { IsolatedDeclarationsOptions } from "oxc-transform"; import type { TranspileOptions } from "typescript"; import type { FilterPattern } from "unplugin"; /** * Represents the options for the plugin. */ export type Options = { include?: FilterPattern; exclude?: FilterPattern; enforce?: "pre" | "post" | undefined; /** * Whether to generate declaration source maps. * * Supported by `typescript` and `oxc` transformer only. * * @link https://www.typescriptlang.org/tsconfig/#declarationMap */ sourceMap?: boolean; ignoreErrors?: boolean; /** An extra directory layer for output files. */ extraOutdir?: string; /** Patch `export default` in `.d.cts` to `export = ` */ patchCjsDefaultExport?: boolean; /** Base directory for input files. */ inputBase?: string; rewriteImports?: (id: string, importer: string) => string | void | null | undefined; } & ({ /** * @default 'oxc' */ transformer?: "oxc"; transformOptions?: Omit; } | { /** * `@swc/core` should be installed yourself. */ transformer?: "swc"; } | { /** * `typescript` should be installed yourself. */ transformer?: "typescript"; /** Only for typescript transformer */ transformOptions?: TranspileOptions; }); type Overwrite< T, U > = Pick> & U; export type OptionsResolved = Overwrite & { transformOptions?: any; }, Pick>; export declare function resolveOptions(options: Options): OptionsResolved; export {};