-
Notifications
You must be signed in to change notification settings - Fork 638
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
removed unused classes. saves about 1kb #870
Conversation
removed unused pure grid classes. saves about 1kb (index.html.gz)
wrote a simple script to list all classes and check if they're used.
|
That's good. My only concern is that we are touching a 3rd party file, which means that this patch should be re-applied if we update the library in the future... |
that's why i didn't touch the main pure.css file. in case the unused classes are needed in the future. but in pure grid, unused classes are for different screen sizes and only lg (>= 1024px) is used. |
Maybe document this with https://github.com/pure-css/pure builder instead of script? Is this the same thing? index 7398e1f..a7f0b5b 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -212,10 +212,7 @@ grunt.initConfig({
options: {
mediaQueries: {
- sm: 'screen and (min-width: 35.5em)', // 568px
- md: 'screen and (min-width: 48em)', // 768px
lg: 'screen and (min-width: 64em)', // 1024px
- xl: 'screen and (min-width: 80em)' // 1280px
}
}
} Different builds:
|
@mcspr : yes, it's the same thing. |
Yes, I'm with @mcspr, using the tools the developer provide seems a better idea. |
removed unused pure grid classes. saves about 1kb (index.html.gz)