Closed hci2 closed 1 week ago
Moreover, I also noticed that the docs are not up-to-date regarding src/assets
and src/favicon.ico
, see: https://angular.dev/reference/configs/workspace-config#assets-configuration.
Hi @hci2, I couldn't reproduce the issue you've mentioned.
Regarding the documentation issue, please open an issue at https://github.com/angular/angular.
Hmmm, that is weird. I double-checked and it worked in Safari and Firefox as well.
I tried different variants and came to this entry in Stackoverflow (https://stackoverflow.com/a/28436056/11494882) to force the browser to refresh via setting <link rel="icon" type="image/x-icon" href="favicon.ico?v=2">
in index.html
and then this finally worked.
After setting version:
We can close this ticket because it has to do with the caching of Chrome and is not related to the code. Thank you anyway for your help.
Command
new
Is this a regression?
The previous version in which this bug was not present was
No response
Description
When scaffolding a new Angular project via
ng new <PROJECT_NAME>
the generatedfavicon.ico
does not work. I just renamed it tofavicon.png
and changed the reference inindex.html
and it works immediately.How about changing the scaffolding to use PNG instead of *.ico?
Minimal Reproduction
favicon.ico (default after generating via
ng create
):favicon.png (after renaming and changing):
Exception or Error
No response
Your Environment
/ △ \ | ' \ /
| | | | |/ _
| '| | | | | | | / _ | | | | (| | || | | (| | | | || |_ | | // __| ||_, |_,||_,|| __|__|| |/Angular CLI: 18.2.8 Node: 20.17.0 Package Manager: npm 10.9.0 OS: darwin arm64
Angular: 18.2.8 ... animations, cli, common, compiler, compiler-cli, core, forms ... platform-browser, platform-browser-dynamic, router
Package Version
@angular-devkit/architect 0.1802.8 @angular-devkit/build-angular 18.2.8 @angular-devkit/core 18.2.8 @angular-devkit/schematics 18.2.8 @schematics/angular 18.2.8 rxjs 7.8.1 typescript 5.5.4 zone.js 0.14.10
Anything else relevant?
IDE: VS Code (1.94.2 (Universal)) Browser: Chrome (129.0.6668.91 (Official Build) (arm64)) OS: MacOS (15.0.1)