gulp-typescript's README says it supports incremental compilation but doesn't explain what is meant by that term in this context.
There's an issue discussing how gulp-typescript incremental compilation is slower than tsc, but it doesn't explain why, or what the difference is.
What is gulp-typescript doing when it does "incremental compilation"?
What I tried
I'm looking at gulp-typescript's source code and it looks like gulp-typescript isn't doing any incremental compilation at all.
When a Project
is created, it closes over an instance of ProjectInfo
, which has an input
member which is a FileCache
. A FileCache is pretty much a mapping from file names to source strings. There isn't much other state that is maintained in a gulp-typescript Project
.
In order to do actual incremental compilation (reusing products of the compilation process in subsequent builds) using the TS compiler API, I would expect to see one of the following:
But I don't see either of those in the source.