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
"Unexpected token found" on @import directives #191
Comments
Workaround for WordpressI had this issue because I'm including the Because there is no css @import anymore, we've a workaround to bypass these bug. And its also better for the performance of the wordpress-theme, since @import will block rendering. Using the way above, the css file is inserted in a normal tag. Most browsers are able to download these css-files parellel. In the ASP.NET Core application, we must only add both of the stylesheets from parent and child-theme in the
Important is, that the parent-theme should be included before the child-theme. WordPress will do the same using the functions.php described above and it make sense: So you're able to override things from the parent-theme, which you want to customize. So it could have unwanted side-effects, if you don't care about those order. |
Same issue with and with |
I have the same issue as above. Any fix coming? |
Visual studio 2017 + Bundle & minifier 2.4.340 i have no issue |
Isn't 2.4.337 the latest..? |
I'm on VS17 with Bundle & minifier 2.5.357, still having the issue with it blowing up on @imports and @Keyframes |
guys, are you going to fix this??? |
Was this ever fixed? |
|
As above, put your new css file above the site.css in the array. Works fine on VS17 with Bundle & minifier 2.8.391. |
I had this problem when I was building the project in the Azure Devops pipeline, and with this tip of creating the css file and placing the import in it and then adding the file inside the bundleconfig.json it worked. Thanks |
IT WORKED FOR ME! Great answer |
Was this ever fixed? |
There are so many limitations in this tools. Is there any better alternative available? |
I'm having issue with files containing
I get, |
I used Gulp in the past, for new projects I'd have a look at Webpack. |
Installed product versions
Description
When a css-file contains @import statements, the minifying-process would fail with the error-message
Steps to recreate
@import url("../style.css");
Expected behavior
The tool should at least leave the import-directive. But the best way would be fetching the referenced file and replace their content with the import-line, this would result in best performance.
The text was updated successfully, but these errors were encountered: