Skip to content

Latest code/html changes not visible in browser. #14804

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

Closed
Ionaru opened this issue Jun 17, 2019 · 3 comments
Closed

Latest code/html changes not visible in browser. #14804

Ionaru opened this issue Jun 17, 2019 · 3 comments

Comments

@Ionaru
Copy link

Ionaru commented Jun 17, 2019

🐞 Bug report

Command (mark with an x)

- [ ] new
- [ ] build
- [x] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Is this a regression?

Yes, the previous version in which this bug was not present was: 8.0.2

Ancient issue that described the same problem: #5117

Description

Auto-reload does not reload latest changes into the browser, instead the one before last change is visible.

🔬 Minimal Reproduction

  1. ng new --style=scss --enable-ivy --routing reload-test
  2. ng g component home
  3. Add {component: HomeComponent, path: ''} as route to app-routing.module.ts
  4. ng serve
  5. Open webpage on http://localhost:4200
  6. Change some HTML or code in HomeComponent.
  7. Save (Recompile will trigger & webpage will reload).
  8. Change is not visible.
  9. Make another change in HomeComponent.
  10. Save (Recompile will trigger & webpage will reload).
  11. First change is visible, but second change isn't.

🌍 Your Environment


Angular CLI: 8.0.3
Node: 12.3.1
OS: win32 x64
Angular: 8.0.1
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.800.3
@angular-devkit/build-angular     0.800.3
@angular-devkit/build-optimizer   0.800.3
@angular-devkit/build-webpack     0.800.3
@angular-devkit/core              8.0.3
@angular-devkit/schematics        8.0.3
@angular/cli                      8.0.3
@ngtools/webpack                  8.0.3
@schematics/angular               8.0.3
@schematics/update                0.800.3
rxjs                              6.4.0
typescript                        3.4.5
webpack                           4.30.0

Additional information

A few things I've noticed:

  • Subsequent saves will trigger another recompile, even though nothing was changed. Each new build also has a unique hash, which is strange because nothing changed.
  • Changes to AppComponent do show up when reloading the webpage. (Problem seems isolated to routes)
@Ionaru
Copy link
Author

Ionaru commented Jun 17, 2019

2019-06-17 23:33 UTC: Updated original comment with better reproduction steps and additional information.

@alan-agius4
Copy link
Collaborator

Duplicate of angular/angular#30947

@alan-agius4 alan-agius4 marked this as a duplicate of angular/angular#30947 Jun 18, 2019
@angular-automatic-lock-bot
Copy link

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.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants