/** * @packageDocumentation * * An rsbuild plugin for config Lynx Config defined by `@lynx-js/type-config`. * * @example * ```ts * import { pluginLynxConfig } from '@lynx-js/config-rsbuild-plugin' * import { defineConfig } from '@lynx-js/rspeedy' * * export default defineConfig({ * plugins: [ * pluginLynxConfig({ * alignMouseEventWithW3C: true, * }), * ], * }) * ``` */ import type { CompilerOptions } from '@lynx-js/type-config'; import type { Config as Config_2 } from '@lynx-js/type-config'; import type { RsbuildPlugin } from '@lynx-js/rspeedy'; /** * A configuration interface for Lynx Config defined by `@lynx-js/type-config`. * * @public */ export declare interface Config extends Config_2, CompilerOptions { } /** * Options for the Lynx Config rsbuild plugin. * * @public */ export declare interface Options { /** * The keys of compiler options to set. */ compilerOptionsKeys?: string[]; /** * The keys of config options to set. */ configKeys?: string[]; /** * Custom validation function for the Lynx config. * * @param input - The input to validate. * @returns The validated Lynx config. */ validate?: (input: unknown) => Config; /** * A map from DSL plugin name to its package name. * * @example * ```ts * { * 'lynx:react': '@lynx-js/react-rsbuild-plugin', * } * ``` */ dslPluginName2PkgName?: Record; /** * The link to upgrade Rspeedy. */ upgradeRspeedyLink?: string; } /** * An rsbuild plugin for config Lynx Config defined by `@lynx-js/type-config`. * * @param config - The Lynx config to set. * * @example * ```ts * import { pluginLynxConfig } from '@lynx-js/config-rsbuild-plugin' * import { defineConfig } from '@lynx-js/rspeedy' * * export default defineConfig({ * plugins: [ * pluginLynxConfig({ * alignMouseEventWithW3C: true, * }), * ], * }) * ``` * * @public */ export declare function pluginLynxConfig(config: Config, options?: Options): RsbuildPlugin; export { }