aegir icon indicating copy to clipboard operation
aegir copied to clipboard

Do not delete dist folder before build or .tsbuildinfo files afterwards

Open achingbrain opened this issue 4 years ago • 0 comments

Typescript supports incremental compilation, we even have it enabled by default, but it works by looking up a .tsbuildinfo from the configured outDir.

Aegir deletes the dist folder before every build and the .tsbuildinfo file after the build so incremental compilation is not possible.

Disabling these deletions locally made the first build time for the full js-IPFS monorepo of about 10 minutes drop to 2 minutes on subsequent builds.

.tsbuildinfo files should be omitted from publishing by adding an exclude to the files array in a project's package.json:

"files": [
  "src",
  "dist",
  "!dist/*.tsbuildinfo"
],

achingbrain avatar Mar 26 '21 16:03 achingbrain