Title: Optimizing javascript makes pictures blurry
Last modified: September 18, 2019

---

# Optimizing javascript makes pictures blurry

 *  Resolved [koleto1](https://wordpress.org/support/users/koleto1/)
 * (@koleto1)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/)
 * Hello,
    when I try to optimize my Javascript I encounter the following issue:
   my pictures on my slideshow on my homepage remain blurry forever. When the js
   scripts are not optimized the images do load in high quality after the page is
   fully loaded. Right now the js optimization is not enabled and loading time is
   high. Otherwise loading time is reduced dramatically, but images remain blurry
   which is not beneficial for me. Any ideas how could I optimize my js but images
   do not become blurry? (I get no errors in the console) Any help will be highly
   appreciated 🙂
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Foptimizing-javascript-makes-pictures-blurry%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Optimizing Matters](https://wordpress.org/support/users/optimizingmatters/)
 * (@optimizingmatters)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11945615)
 * Well, try:
    1. adding `themes/uncode/library/js/` to the comma-separated JS optimization
   exclusion list and see if it works 2. and if that doesn’t work try unticking `
   aggregate JS` and see if it works
 * hope this helps,
    frank
 *  Thread Starter [koleto1](https://wordpress.org/support/users/koleto1/)
 * (@koleto1)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11947466)
 * When I add this to the comma-separated JS optimization exclusion and the aggregate
   JS is ticked, loading time is reduced greatly because it makes fewer HTTP requests
   and the pictures do load properly, however, I get a couple of JS errors in the
   console and lose the arrows which change the pictures, the dots and the slideshow
   breaks down. When aggregate JS is unticked it works fine but loading time is 
   way worse. Here the JS errors, any clues whether it is possible to make further
   optimization? Right now the not-working version is online, so that you are able
   to see the JS errors.
    Thank you 🙂
 * autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.php?ver=1061673030:26 Uncaught
   TypeError: Cannot read property ‘classList’ of undefined
    at Object.hasClass (
   autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.php?ver=1061673030:26) at
   setRowHeight (autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.php?ver=1061673030:
   111) at autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.php?ver=1061673030:
   186 autoptimize_single_4e22e663fde466ae66542c74b2a93fee.php?ver=1061673030:32
   Uncaught ReferenceError: jQuery is not defined at autoptimize_single_4e22e663fde466ae66542c74b2a93fee.
   php?ver=1061673030:32 autoptimize_single_c83cd3655cb89a932d1c32888b486efe.php?
   ver=1061673030:301 Uncaught ReferenceError: jQuery is not defined at autoptimize_single_c83cd3655cb89a932d1c32888b486efe.
   php?ver=1061673030:301 (index):1 Unchecked runtime.lastError: The message port
   closed before a response was received. autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.
   php?ver=1061673030:186 Uncaught ReferenceError: Waypoint is not defined at autoptimize_single_1ea822c0e7e4ea554f3f46fa00684682.
   php?ver=1061673030:186
 *  Plugin Author [Optimizing Matters](https://wordpress.org/support/users/optimizingmatters/)
 * (@optimizingmatters)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11947546)
 * let’s start with `Uncaught ReferenceError: jQuery is not defined`; can you add`
   js/jquery/jquery.js` to the JS optimization exclusion list as well?
 *  Thread Starter [koleto1](https://wordpress.org/support/users/koleto1/)
 * (@koleto1)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11947585)
 * That actually fixed all the errors! Thank you!
 *  Plugin Author [Optimizing Matters](https://wordpress.org/support/users/optimizingmatters/)
 * (@optimizingmatters)
 * [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11947595)
 * you’re welcome, feel free to [leave a review of the plugin and support here](https://wordpress.org/support/plugin/autoptimize/reviews/#new-post)!
   🙂

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Optimizing javascript makes pictures blurry’ is closed to new replies.

 * ![](https://ps.w.org/autoptimize/assets/icon-256X256.png?rev=2211608)
 * [Autoptimize](https://wordpress.org/plugins/autoptimize/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/autoptimize/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/autoptimize/)
 * [Active Topics](https://wordpress.org/support/plugin/autoptimize/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/autoptimize/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/autoptimize/reviews/)

## Tags

 * [blurry images](https://wordpress.org/support/topic-tag/blurry-images/)
 * [js-optimization](https://wordpress.org/support/topic-tag/js-optimization/)

 * 5 replies
 * 2 participants
 * Last reply from: [Optimizing Matters](https://wordpress.org/support/users/optimizingmatters/)
 * Last activity: [6 years, 8 months ago](https://wordpress.org/support/topic/optimizing-javascript-makes-pictures-blurry/#post-11947595)
 * Status: resolved