Comments (8)
Thanks for the bug report. Would it be possible to share a minimal test case reproducing the issue? Alternatively a summary of whether there are complex selectors in your stylesheet would help us nail down the issue.
cc @giakki in case this happens upstream too.
from grunt-uncss.
It is not happening upstream, actually. I added a specific tests for :hover, and it passes without problems, and so does the example page from grunt-uncss.
IIRC, the method for parsing unused selectors hasn't changed between the two versions, could you share an example of it happening, so I can look into it?
Thanks!
from grunt-uncss.
here's a stripped down version of my environment: https://www.dropbox.com/s/aq2utuvymc5dwxm/uncss-test.zip
to reiterate, i tested it before the latest pull and it seemed to be working fine except for html files that were too big (that bug was fixed) and the stylesheets option (that seems to have also been fixed). however, now the uncss stylesheet is half the size of what it was previously, and it's missing important styles.
note: the changes i made to my stylesheet in between tests is negligible. simple style updates here and there - nothing that would affect overall style structure, etc.
from grunt-uncss.
Thanks, I'll try and check what's wrong ASAP!
from grunt-uncss.
Could you try out 0.1.9 and let me know if this is still an issue?
@giakki were you able to find out if this is an issue upstream?
from grunt-uncss.
@addyosmani updating to the newest version there are 3 main changes:
- the uncss task is noticably longer. on my project it clocked in at a whopping 2 minutes. i don't remember it ever taking more than 20 seconds before this last update...
- my screen.un.css is now at its expected size again -- 72kb again, which is good!
- pretty much all the CSS works perfectly except for hovers in my navigation unless i put in some special ignore options. for example, class="hoverable" is in the HTML file, but none of the .hoverable declerations get included in the un.css file unless i put "ignore: [/hoverable/," in the options. note: i did not have to "hack" it to fix it in earlier versions.
overall: definitely happier, but something still seems a little fishy! also the whole 2 minute task thing dissuades me from integrating this into general workflow...
thanks guys!
from grunt-uncss.
Sorry for the delay, I'm happy you managed to get it working at least!
I'll look into the two issues that you mentioned, especially the performance one looks strange.
Thanks again!
from grunt-uncss.
I believe @giakki attempted to address some of the regressions introducing performance issues back in 35 (upstream). This shouldn't be as slow now.
from grunt-uncss.
Related Issues (20)
- Incomplete css HOT 1
- Sync Multiple Vscode?
- Missing dependency of PhantomJS HOT 1
- Regex in src urls HOT 3
- JS errors without inline scripts HOT 1
- Fatal error: Cannot communicate with PhantomJS process: PhantomJS exited unexpectedly: read ECONNRESET HOT 2
- Not taking into account the classes that are added through angular HOT 5
- does it conflict with JQuery HOT 2
- bootstrap alert not processed HOT 1
- Grunt uncss fails silently mac HOT 2
- "ignoreSheets : [/fonts.googleapis/]" isn't ignoring Google fonts HOT 1
- Fatal error: connect ECONNREFUSED 127.0.1.1:80 HOT 2
- Fatal error: uncss/node_modules/css: unable to parse... Excessive slag in URI. HOT 2
- UnhandledPromiseRejectionWarning: Unhandled promise rejection HOT 2
- file.src should be file.orig.src (grunt 1.0.1)
- ignore doesn't work HOT 2
- GitHub Actions CI HOT 3
- Timing Problems with many files HOT 1
- Remove deprecated request package
- Does this work project-wide with SASS files?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from grunt-uncss.