Skip to content

Commit

Permalink
chore: update
Browse files Browse the repository at this point in the history
  • Loading branch information
Timeless0911 committed Nov 29, 2024
1 parent 37bc7ee commit 1e7247f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/plugin-dts/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,20 +111,24 @@ export const pluginDts = (options: PluginDtsOptions = {}): RsbuildPlugin => ({
childProcesses.push(childProcess);

const { cleanDistPath } = config.output;

console.time(`clean dts files ${environment.name}`);
// clean dts files
if (cleanDistPath !== false) {
await cleanDtsFiles(dtsEmitPath);
}
console.timeEnd(`clean dts files ${environment.name}`);

console.time(`clean .rslib temp folder ${environment.name}`);
// clean .rslib temp folder
if (options.bundle) {
await clearTempDeclarationDir(cwd);
}
console.timeEnd('clean .rslib temp folder');

console.time(`clean tsbuildinfo file ${environment.name}`);
// clean tsbuildinfo file
await cleanTsBuildInfoFile(tsconfigPath, tsConfigResult);

console.timeEnd(`clean tsbuildinfo file ${environment.name}`);
const dtsGenOptions: DtsGenOptions = {
...options,
dtsEntry,
Expand Down

0 comments on commit 1e7247f

Please sign in to comment.