Interface: DtsOptions
Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:156
Extends
GeneralOptions.TscOptions
Properties
banner?
optional banner: string | Promise<string> | AddonFunction;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:150
Content to be added at the top of each generated .d.ts file.
Inherited from
TscOptions.bannerbuild?
optional build: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:77
Build mode for the TypeScript compiler:
- If
true, the plugin will usetsc -bto build the project and all referenced projects before emitting.d.tsfiles. - If
false, the plugin will usetscto emit.d.tsfiles without building referenced projects.
Default
falseInherited from
TscOptions.buildcjsDefault?
optional cjsDefault: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:66
Determines how the default export is emitted.
If set to true, and you are only exporting a single item using export default ..., the output will use export = ... instead of the standard ES module syntax. This is useful for compatibility with CommonJS.
Inherited from
GeneralOptions.cjsDefaultcompilerOptions?
optional compilerOptions: CompilerOptions;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:44
Override the compilerOptions specified in tsconfig.json.
See
https://www.typescriptlang.org/tsconfig/#compilerOptions
Inherited from
GeneralOptions.compilerOptionscwd?
optional cwd: string;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:11
The directory in which the plugin will search for the tsconfig.json file.
Inherited from
GeneralOptions.cwddtsInput?
optional dtsInput: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:17
Set to true if your entry files are .d.ts files instead of .ts files.
When enabled, the plugin will skip generating a .d.ts file for the entry point.
Inherited from
GeneralOptions.dtsInputeager?
optional eager: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:126
If true, the plugin will prepare all files listed in tsconfig.json for tsc or vue-tsc.
This is especially useful when you have a single tsconfig.json for multiple projects in a monorepo.
Inherited from
TscOptions.eageremitDtsOnly?
optional emitDtsOnly: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:23
If true, the plugin will emit only .d.ts files and remove all other output chunks.
This is especially useful when generating .d.ts files for the CommonJS format as part of a separate build step.
Inherited from
GeneralOptions.emitDtsOnlyemitJs?
optional emitJs: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:146
If true, the plugin will emit .d.ts files for .js files as well. This is useful when you want to generate type definitions for JavaScript files with JSDoc comments.
Enabled by default when allowJs in compilerOptions is true. This option is only used when Options.oxc is false.
Inherited from
TscOptions.emitJsfooter?
optional footer: string | Promise<string> | AddonFunction;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:154
Content to be added at the bottom of each generated .d.ts file.
Inherited from
TscOptions.footerincremental?
optional incremental: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:107
If your tsconfig.json has references option, rolldown-plugin-dts will use tsc -b to build the project and all referenced projects before emitting .d.ts files.
In such case, if this option is true, rolldown-plugin-dts will write down all built files into your disk, including .tsbuildinfo and other built files. This is equivalent to running tsc -b in your project.
Otherwise, if this option is false, rolldown-plugin-dts will write built files only into memory and leave a small footprint in your disk.
Enabling this option will decrease the build time by caching previous build results. This is helpful when you have a large project with multiple referenced projects.
By default, incremental is true if your tsconfig has incremental or tsBuildInfoFile enabled.
This option is only used when Options.oxc is false.
Inherited from
TscOptions.incrementalnewContext?
optional newContext: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:137
If true, the plugin will create a new isolated context for each build, ensuring that previously generated .d.ts code and caches are not reused.
By default, the plugin may reuse internal caches or incremental build artifacts to speed up repeated builds. Enabling this option forces a clean context, guaranteeing that all type definitions are generated from scratch.
Default
falseInherited from
TscOptions.newContextoxc?
optional oxc: boolean | Omit<IsolatedDeclarationsOptions, "sourcemap">;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:163
If true, the plugin will generate .d.ts files using Oxc, which is significantly faster than the TypeScript compiler.
This option is automatically enabled when isolatedDeclarations in compilerOptions is set to true.
parallel?
optional parallel: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:120
If true, the plugin will launch a separate process for tsc or vue-tsc. This enables processing multiple projects in parallel.
Inherited from
TscOptions.parallelresolve?
optional resolve: boolean | (string | RegExp)[];Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:58
Controls whether type definitions from node_modules are bundled into your final .d.ts file or kept as external import statements.
By default, dependencies are external, resulting in import { Type } from 'some-package'. When bundled, this import is removed, and the type definitions from some-package are copied directly into your file.
true: Bundles all dependencies.false: (Default) Keeps all dependencies external.(string | RegExp)[]: Bundles only dependencies matching the provided strings or regular expressions (e.g.['pkg-a', /^@scope//]).
Inherited from
GeneralOptions.resolvesourcemap?
optional sourcemap: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:48
If true, the plugin will generate declaration maps (.d.ts.map) for .d.ts files.
Inherited from
GeneralOptions.sourcemaptsconfig?
optional tsconfig: string | boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:32
The path to the tsconfig.json file.
If set to false, the plugin will ignore any tsconfig.json file. You can still specify compilerOptions directly in the options.
Default
'tsconfig.json'Inherited from
GeneralOptions.tsconfigtsconfigRaw?
optional tsconfigRaw: Omit<TsConfigJson, "compilerOptions">;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:38
Pass a raw tsconfig.json object directly to the plugin.
See
https://www.typescriptlang.org/tsconfig
Inherited from
GeneralOptions.tsconfigRawtsgo?
optional tsgo: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:172
[Experimental] Enables DTS generation using tsgo.
To use this option, make sure @typescript/native-preview is installed as a dependency.
Note: This option is not yet recommended for production environments. tsconfigRaw and isolatedDeclarations options will be ignored when this option is enabled.
tsMacro?
optional tsMacro: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:115
If true, the plugin will generate .d.ts files using @ts-macro/tsc.
Inherited from
TscOptions.tsMacrovue?
optional vue: boolean;Defined in: node_modules/.pnpm/rolldown-plugin-dts@0.17.2_rolldown@1.0.0-beta.45_typescript@5.9.3_vue-tsc@3.1.2_typescript@5.9.3_/node_modules/rolldown-plugin-dts/dist/index.d.ts:111
If true, the plugin will generate .d.ts files using vue-tsc.
Inherited from
TscOptions.vue