Critical CSS and WooCommerce
-
I have found that when Critical CSS is enabled, it pulls in a WooCommerce CSS file, woocommerce-smallscreen.css, but does not include the wrapping media query for max 768 screen size. I disabled all of the Optimization settings then enabled one at a time and Generate Critical CSS is the setting that causes the problems.
I put woocommerce-smallscreen.css in the CSS Excludes in Tuning, but it does not help with the Critical CSS problem. The product columns, which should be 22.05% width on larger screens are being displayed at 48%, which should only happen under 768px.
Is there are Critical CSS Rule that can help?
I think this is the style that is causing the problem:
.woocommerce ul.products[class*=columns-] li.product, .woocommerce-page ul.products[class*=columns-] li.product { width: 48%; float: left; clear: both; margin: 0 0 2.992em }
I tried adding a rule in the Critical CSS rules, for min width 768px, but couldn’t get it quite right.
The page I need help with: [log in to see the link]
- The topic ‘Critical CSS and WooCommerce’ is closed to new replies.