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

Extract:true gives wrong output on absolute paths, and if an external stylesheet is in the markup #61

Closed
alanontheweb opened this issue Feb 4, 2015 · 3 comments

Comments

@alanontheweb
Copy link

NOTE - This was only tested with the new Stream functionality.

Example - Using the new Stream functionality and Extract:true, Gulp is globbing through several HTML files, and some are in subdirectories. In my HTML, my stylesheet path is "/assets/css/app.min.css" (note the slash at the beginning).

This does not work or result in generating multiple partial CSS files, and it doesn't append the appropriate filename to the LoadCSS snippet functions.

Removing the front slash to just "assets/css/app.min.css" MAKES THE WHOLE THING WORK. However, once the files are outputted, the loadCSS is pointing to a relative asset, and this breaks the pages that are inside a subdirectory, since it can't find the CSS there.

to recap - It does work with both absolute and relative paths, as long as you don't use the extract function (which creates its own unique stylesheet per page). If you use extract: true, then it only works with a relative path.

Also, with extract: true, the loadCSS function appends no path for the stylesheet.

Lastly, extract:true also gets hung up if an external stylesheet is defined in the markup.

@bezoerb
Copy link
Collaborator

bezoerb commented Jun 10, 2015

@alanontheweb just added a fix to inline-critical. Want to give it another try?

@bezoerb
Copy link
Collaborator

bezoerb commented Jul 13, 2015

@alanontheweb any updates here?

@bezoerb
Copy link
Collaborator

bezoerb commented Jul 1, 2017

Closing this due to lack of feedback. Feel free to reopen if the problem still exists

@bezoerb bezoerb closed this as completed Jul 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants