zephyr-rspress-plugin
Version:
Rspress plugin for Zephyr
35 lines • 1.14 kB
TypeScript
import { type ZephyrBuildHooks } from 'zephyr-rsbuild-plugin';
import type { ZephyrBuildTarget } from 'zephyr-agent';
import type { RspressUserConfig, RspressPlugin } from './types/index.js';
export interface ZephyrRspressOptions {
/** Zephyr artifact family, including `tap-app` for TAP packages. */
target?: ZephyrBuildTarget;
hooks?: ZephyrBuildHooks;
}
/**
* Creates a Zephyr plugin for Rspress that works with both v1 and v2
*
* @example
* ```ts
* // rspress.config.ts (v1)
* import { defineConfig } from 'rspress/config';
* import { withZephyr } from 'zephyr-rspress-plugin';
*
* export default defineConfig({
* plugins: [withZephyr()],
* });
* ```;
*
* @example
* ```ts
* // rspress.config.ts (v2)
* import { defineConfig } from '@rspress/core';
* import { withZephyr } from 'zephyr-rspress-plugin';
*
* export default defineConfig({
* plugins: [withZephyr()],
* });
* ```;
*/
export declare function withZephyr<TConfig extends RspressUserConfig = RspressUserConfig>(options?: ZephyrRspressOptions): RspressPlugin<TConfig>;
//# sourceMappingURL=with-zephyr.d.ts.map