Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop inspecting output strings to determine when builds complete #209

Merged
merged 1 commit into from May 15, 2018

Conversation

dfreeman
Copy link
Member

TypeScript 2.9 tweaked their diagnostic message when a build completes, which prompted me to finally go find a hook for reporting rebuilds that doesn't involve string sniffing. I tested this against 2.7, 2.8, and next and everything looked good across those three.

I'm also going to look at including different typescript versions in our build matrix, but figured I'd do that in a separate PR.

Copy link
Member

@chriskrycho chriskrycho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Yay!
  2. I really wish these pieces were better-documented. Where did you find this documented?

@@ -97,14 +97,11 @@ module.exports = class IncrementalTypescriptCompiler {

this._watchProgram = compile(project, { outDir, watch: true }, {
watchedFileChanged: () => this.state.tscDidStart(),
buildComplete: () => this.state.tscDidEnd(),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😍

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so much better!

@dfreeman
Copy link
Member Author

I found a mention of afterProgramCreate in the original PR for the watch API and then confirmed its existence here

@dfreeman dfreeman merged commit c46ec3b into master May 15, 2018
@dfreeman dfreeman deleted the ts-2-9-support branch May 15, 2018 01:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants