-
-
Notifications
You must be signed in to change notification settings - Fork 265
Open
Description
I have a package with some legacy js which I need to copy verbatim which includes some basic d.ts files. When running the build with clean enabled the files are being copied to the output directory but then subsequently deleted, which upon investgation seems to be happening in the dtsTask.
I tried using the onSuccess hook but it has the same issue:
onSuccess: async () => {
fs.cpSync('./public', './dist/', { recursive: true });
},
I managed to workaround this issue by putting a delay in the onSuccess great than the DTS build step:
onSuccess: async () => {
setTimeout(() => {
fs.cpSync('./public', './dist/', { recursive: true });
}, 5000);
},
Suggested resolution:
Run the publicDir and onSuccess tasks after the dtsTask and the mainTasks have completed. In fact I would think the onSuccess should be run after the publicDir.
wbobeirne
Metadata
Metadata
Assignees
Labels
No labels