Skip to content

ngc --watch ignores changes in templates (ivy) #31982

Closed

Description

@stefanocke

🐞 bug report

Affected Package

The issue is caused by package @angular/compiler-cli

Is this a regression?

Yes, the previous version in which this bug was not present was: 8.1.2
(But, due to #31322, it only worked on every second change of a template.)

Description

  • I run ngc in watch mode. Output directory is out-tsc.
  • Ivy is enabled.
  • I change a component's template.
  • ngc says "File change detected. Starting incremental compilation."
  • However, the template change does not result in an according change in the *.js file in out-tsc directory.
  • For changes in *.ts files, it works.

🔬 Minimal Reproduction

Example project is at: https://github.com/stefanocke/angular-cli-app-with-rollup
Please run:

npm i
npm run ngc-app-watch

Then, change app.component.html and look for app.component.js in tsc-out.

🌍 Your Environment

Angular Version:


Angular CLI: 8.2.0
Node: 10.16.0
OS: win32 x64
Angular: 8.2.0
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, router

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.802.0
@angular-devkit/build-angular     0.802.0
@angular-devkit/build-optimizer   0.802.0
@angular-devkit/build-webpack     0.802.0
@angular-devkit/core              8.2.0
@angular-devkit/schematics        8.2.0
@ngtools/webpack                  8.2.0
@schematics/angular               8.2.0
@schematics/update                0.802.0
rxjs                              6.5.2
typescript                        3.5.3

Anything else relevant?
Ivy is enabled

Activity

  1. modified the milestone: needsTriage on Aug 6, 2019
  2. alxhub commented on Aug 8, 2019

    @alxhub
    Member

    This is fixed in #31932 :D

  3. alxhub commented on Aug 8, 2019

    @alxhub
    Member

    Also closing as a duplicate.

  4. stefanocke commented on Aug 13, 2019

    @stefanocke
    Author

    @alxhub , thank you. Is it supposed to be part of Angular 8.2.2 ? It seems not to work yet.

    Same result with 9.0.0-next.2.

  5. stefanocke commented on Aug 24, 2019

    @stefanocke
    Author

    @alxhub , it is still not working with 9.0.0-next.3
    See https://github.com/stefanocke/angular-cli-app-with-rollup (steps tor reproduce see above)

    Would you please reconsider / reopen?

  6. angular-automatic-lock-bot commented on Sep 24, 2019

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  7. locked and limited conversation to collaborators on Sep 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: compilerIssues related to `ngc`, Angular's template compiler

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions