> For AI agents: the complete documentation index is available at https://rsdoctor.rs/llms.txt, the full documentation bundle is available at https://rsdoctor.rs/llms-full.txt.

# Overview

## RsdoctorRspackPlugin

The `RsdoctorRspackPlugin` class is exported from `@rsdoctor/core`. Its configuration type is [RsdoctorRspackPluginOptions](#rsdoctorrspackpluginoptions).

```ts
import { RsdoctorRspackPlugin } from '@rsdoctor/core';

new RsdoctorRspackPlugin({/** RsdoctorRspackPluginOptions */});
```

## Options

**Type:** `Object`

This `Options` object is the configuration for [RsdoctorRspackPlugin](#rsdoctorrspackplugin). It contains the following properties:

- [disableClientServer](https://rsdoctor.rs/config/options/disableClientServer.md) - **Report Server Control**: Whether to shut down the Rsdoctor report server after analysis is complete.
- [features](https://rsdoctor.rs/config/options/features.md) - **Feature Toggle Configuration**: Control various analysis features of Rsdoctor, such as loader analysis, bundle analysis, rule checking, etc.
- [output](https://rsdoctor.rs/config/options/output.md) - **Output Related Configuration**: Control report output format, directory and other options, including mode, options, reportCodeType, etc.
- [server](https://rsdoctor.rs/config/options/server.md) - **Report Server Configuration**: Configure the Rsdoctor report server, including `server.port` and `server.cors`.
- [supports](https://rsdoctor.rs/config/options/supports.md) - **Analysis settings**: Control bundle parsing and compressed size calculation.
- [multiCompiler](https://rsdoctor.rs/config/options/multiCompiler.md) - **Multi-compiler Configuration**: Automatically detect and isolate reports for Rspack MultiCompiler and Rsbuild environments.

### RsdoctorRspackPluginOptions

```ts
interface RsdoctorRspackPluginOptions<
  Rules extends LinterType.ExtendRuleData[],
> {
  multiCompiler?: boolean | { group?: string };

  /** Linter configuration */
  linter?: LinterType.Options<Rules, InternalRules>;

  /** Rsdoctor feature toggles */
  features?:
    RsdoctorRspackPluginFeatures | Array<keyof RsdoctorRspackPluginFeatures>;

  disableClientServer?: boolean;

  supports?: ISupport;

  server?: SDK.RsdoctorServerConfig;

  output?: Config.IOutput<'brief' | 'normal'>;
}
```
