Skip to content
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

CSS assets with same name are overwritten #11117

Closed
TomVanWemmel opened this issue Jun 5, 2018 · 2 comments
Closed

CSS assets with same name are overwritten #11117

TomVanWemmel opened this issue Jun 5, 2018 · 2 comments
Labels
area: devkit/build-angular freq1: low Only reported by a handful of users who observe it rarely severity3: broken type: bug/fix
Milestone

Comments

@TomVanWemmel
Copy link

Versions


     _                      _                 ____ _     ___
    / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
   / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
  / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
 /_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
                |___/


Angular CLI: 6.0.7
Node: 9.5.0
OS: darwin x64
Angular: 6.0.3
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.6.7
@angular-devkit/build-angular     0.6.7
@angular-devkit/build-optimizer   0.6.7
@angular-devkit/core              0.6.7
@angular-devkit/schematics        0.6.7
@angular/cli                      6.0.7
@ngtools/webpack                  6.0.7
@schematics/angular               0.6.7
@schematics/update                0.6.7
rxjs                              6.2.0
typescript                        2.7.2
webpack                           4.8.3

Repro steps

  • ng new my-project
  • cd my-project
  • npm install flag-icon-css
  • add "node_modules/flag-icon-css/css/flag-icon.min.css" to styles in angular.json
  • ng build
  • ls dist/my-project
  • ng build --output-hashing=all
  • ls dist/my-project

Observed behavior

The flag-icon-css package defines a stylesheet with links to svg files. There are two svg files (squared and rectangular flag) for each supported country, both have the same name but are located in a different folder.
For a build without arguments, a list of svg files is shown, only one for each country supported by the css file.
With --output-hashing all svg files are shown.

Desired behavior

ng build should copy all files to the dist folder.

@alan-agius4 alan-agius4 added the freq1: low Only reported by a handful of users who observe it rarely label Oct 30, 2018
@ngbot ngbot bot added this to the needsTriage milestone Oct 30, 2018
@ngbot ngbot bot modified the milestones: needsTriage, Backlog Oct 30, 2018
@alan-agius4
Copy link
Collaborator

alan-agius4 commented Oct 30, 2018

Relates to #12186

You can set outputHashing to media. This will prevent identically named files from overwriting each other (unless the content is identical which is actually favorable).

@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 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: devkit/build-angular freq1: low Only reported by a handful of users who observe it rarely severity3: broken type: bug/fix
Projects
None yet
Development

No branches or pull requests

3 participants