File tree 2 files changed +10
-4
lines changed
2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -302,9 +302,7 @@ namespace ts {
302
302
// There is no extra check needed since we can just rely on the program to decide emit
303
303
const builder = createBuilder ( { getCanonicalFileName, computeHash } ) ;
304
304
305
- if ( watchingHost . system . clearScreen ) {
306
- watchingHost . system . clearScreen ( ) ;
307
- }
305
+ clearHostScreen ( ) ;
308
306
reportWatchDiagnostic ( createCompilerDiagnostic ( Diagnostics . Starting_compilation_in_watch_mode ) ) ;
309
307
synchronizeProgram ( ) ;
310
308
@@ -496,10 +494,14 @@ namespace ts {
496
494
scheduleProgramUpdate ( ) ;
497
495
}
498
496
499
- function updateProgram ( ) {
497
+ function clearHostScreen ( ) {
500
498
if ( watchingHost . system . clearScreen ) {
501
499
watchingHost . system . clearScreen ( ) ;
502
500
}
501
+ }
502
+
503
+ function updateProgram ( ) {
504
+ clearHostScreen ( ) ;
503
505
504
506
timerToUpdateProgram = undefined ;
505
507
reportWatchDiagnostic ( createCompilerDiagnostic ( Diagnostics . File_change_detected_Starting_incremental_compilation ) ) ;
Original file line number Diff line number Diff line change @@ -117,6 +117,10 @@ namespace ts.tscWatch {
117
117
index ++ ;
118
118
} ) ;
119
119
if ( ! skipWaiting ) {
120
+ if ( errorsPosition === ExpectedOutputErrorsPosition . BeforeCompilationStarts ) {
121
+ assertWatchDiagnosticAt ( host , index , ts . Diagnostics . Starting_compilation_in_watch_mode ) ;
122
+ index += 1 ;
123
+ }
120
124
assertWatchDiagnosticAt ( host , index , Diagnostics . Compilation_complete_Watching_for_file_changes ) ;
121
125
}
122
126
host . clearOutput ( ) ;
You can’t perform that action at this time.
0 commit comments