Skip to content

index.html changes not picked up by ng build --watch #23851

Closed

Description

@alcroito

Command

build

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

No response

Description

Touching the project index.html file does not rebuild the application when using ng build --watch.
It does rebuild when using ng serve.

Using ng build -c development --watch doesn't make a difference.

Minimal Reproduction

Create new workspace with ng new someapp, choose default settings.
Run cd someapp && ng build --watch and wait for build to finish.
In a separate terminal run touch src/index.html. Observe no rebuild is happening.
Whereas touching index.html when using ng serve does cause a rebuild.

Exception or Error

No response

Your Environment

Angular CLI: 14.2.1
Node: 16.16.0
Package Manager: npm 8.11.0
OS: linux x64

Angular: 14.2.0
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router, upgrade

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1402.1
@angular-devkit/build-angular   14.2.1
@angular-devkit/core            14.2.1 (cli-only)
@angular-devkit/schematics      14.2.1
@angular/cli                    14.2.1
@schematics/angular             14.2.1
rxjs                            7.5.6
typescript                      4.7.4

Anything else relevant?

No response

Activity

  1. added a commit that references this issue on Sep 2, 2022
    204527c
  2. self-assigned this
    on Sep 2, 2022
  3. added a commit that references this issue on Sep 2, 2022
    3afd784
  4. angular-automatic-lock-bot commented on Oct 3, 2022

    @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.

  5. locked and limited conversation to collaborators on Oct 3, 2022
  6. added a commit that references this issue on Feb 19, 2025
    130975c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions