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

fix(@angular/cli): fix css url processing #4803

Merged
merged 2 commits into from
Feb 20, 2017

Conversation

filipesilva
Copy link
Contributor

@filipesilva filipesilva commented Feb 17, 2017

Fixing component css in #4667 uncovered errors in CSS url processing.

This PR correctly composes absolute urls when using --base-href and/or --deploy-url.

It also fixes asset output on --aot mode. Thanks to @clydin for finding out assets were being dropped in the child compiler.

Fix #4778
Fix #4782
Fix #4806

Copy link
Contributor

@Brocco Brocco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work, LGTM!

@filipesilva filipesilva force-pushed the css-urls branch 2 times, most recently from 856d36d to 3fadf6a Compare February 18, 2017 11:00
@filipesilva filipesilva reopened this Feb 18, 2017
@filipesilva
Copy link
Contributor Author

Still having some problems with the eject config, I need to ask @hansl for advice on it next week.

Fixing component css in angular#4667 uncovered errors in CSS url processing.

This PR correctly composes absolute urls when using `--base-href` and/or `--deploy-url`.

It also fixes asset output on `--aot` mode.

Fix angular#4778
Fix angular#4782
Fix angular#4806
@filipesilva filipesilva changed the title fix(@angular/cli): correctly compose absolute urls fix(@angular/cli): fix css url processing Feb 20, 2017
@omargon
Copy link

omargon commented Feb 24, 2017

@filipesilva thanks for the fix. Do you know when it will be release and/or if there is a workaround in the meantime?

@filipesilva
Copy link
Contributor Author

@omargon workaround would be to use absolute image paths. This will come out next release, which should be early next week I think.

@omargon
Copy link

omargon commented Feb 24, 2017

@filipesilva thanks.

@es-lab
Copy link

es-lab commented Mar 5, 2017

I'm serving assets on a subdomain, and I need to set the deployUrl=http://sub.domain.com/, this worked on version beta26, but now with rc1 this is broken, and I think it is because of this fix you have done here.
In the generated code I see everywhere my deployUrl written like this: /http:/sub.domain.com/assets/...
It reads it as an absolute path relative to the url on which the files were served.

@clydin
Copy link
Member

clydin commented Mar 5, 2017

@es-lab please open an issue so that we can properly assist you.

@es-lab
Copy link

es-lab commented Mar 6, 2017

@clydin I've opened the issue here #5254

asnowwolf pushed a commit to asnowwolf/angular-cli that referenced this pull request Apr 12, 2017
Fixing component css in angular#4667 uncovered errors in CSS url processing.

This PR correctly composes absolute urls when using `--base-href` and/or `--deploy-url`.

It also fixes asset output on `--aot` mode.

Fix angular#4778
Fix angular#4782
Fix angular#4806
@HelloPb
Copy link

HelloPb commented Feb 23, 2018

background: url('assets/client/img.png') is throwing compilation error for ng build -prod

@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 12, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
7 participants