question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItΒ collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

html file replacement doesn't work

See original GitHub issue

🐞 Bug report

Command (mark with an x)

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

Description

After upgrading to Angular 8 file replacement stopped working for html files.

πŸ”¬ Minimal Reproduction

https://github.com/diogen737/fileReplacement-test

Expexted behavior

since there’s html replacement config in angular.json after ng build --prod I expect to see
β€œthis is prod index” on top of the page (localhost:8080/tester) which is present in index.prod.html and absent in index.html from which I conclude that html filre replacement is not working anymore.

🌍 Your Environment


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

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

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:19
  • Comments:26 (3 by maintainers)

github_iconTop GitHub Comments

26reactions
dottodotcommented, May 31, 2019

@alan-agius4 This really should have been mentioned as a breaking change in the release information

14reactions
alan-agius4commented, Jul 11, 2019

@clydin implemented https://github.com/angular/angular-cli/pull/15010 which offers more control over the index html and is available in the 8.2 beta version.

Apologies for any inconvenience caused.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Angular 9: file replacements doesn't work - Stack Overflow
Angular fileReplacements doesn't replace files if they occur in assets . This code doesn't work in Angular 9 but works in version 8:...
Read more >
Work with HTML documents in TextEdit on Mac - Apple Support
Always open HTML files in code-editing mode Β· In the TextEdit app on your Mac, choose TextEdit > Settings, then click Open and...
Read more >
Troubleshoot damaged InDesign documents - Adobe Support
Are you facing issues while opening or saving InDesign files? Read on to learn about the possible reasons and resolutions.
Read more >
Features | Vite
Vite only performs transpilation on .ts files and does NOT perform type checking ... Use the Type-Only Imports and Export syntax to avoid...
Read more >
Hyperlinks not working in Outlook? How to make links open ...
I found default ot set yet, then I modify to html file. then it work. I don't know history of my neqw purchesed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found