Anyway to compress CSS/JS and other assets loading through Foxycart

flinx777flinx777 Member
in General edited September 2015
We are wrapping up a site and running the site through the following Google speed test tool:

https://developers.google.com/speed/pagespeed/insights/

We failed 3 of the results b/c of the Foxycart code loading not being compressed:

* Enable Compression
* Minify CSS (http://cdn.foxycart.com/secure.zuna.com/responsive_styles.1441762820.css)
* Minify JS (to be fair, it says there's only 1% compression needed)

There's really nothing we can do on our end. Is there any plans on Foxycart's end to compress the code that is loaded through the Foxycart JS we load into the site?

<script src="//cdn.foxycart.com/secure.zuna.com/loader.js" async defer></script>

Thanks!
Tagged:
Comments
  • fc_adamfc_adam FoxyCart Team
    @flinx777,

    Great to hear that you're wrapping up the project! Good luck with the last steps.
    * Enable Compression
    Our assets, both loader.js and the CSS and JS that it loads are all served gzip compressed - which you can confirm by checking the network tab of your browsers inspection tools. I just did a quick test of my on test page with PageSpeed and it's actually noting our JSONP cart requests. I'll speak with the team about those.
    * Minify CSS
    Our CSS isn't currently minified as it's reporting. We do have plans to enable that, but have some issues to work through relating to scripts on our side with minifying the dynamically created code for stores. Unfortunately I don't have an ETA on that, but it's something we do want to enable.
    * Minify JS (to be fair, it says there's only 1% compression needed)
    I believe what it's picked up there is the dynamic portion of the store javascript that has been added which is uncompressed. As you noted, the vast majority of our javascript is minified - just a very small portion added dynamically based on the store configuration is not. We'll create a ticket to look at ensuring all code there is minified too.
  • @fc_adam

    Thanks for the breakdown on that. I'll relay this to the client.
Sign In or Register to comment.