• Resolved jesshamm312

    (@jesshamm312)


    Hi,

    I keep getting uncaught type errors (see below for example, but it is not always the same) that somehow prevent pictures from loading, but then everything loads fine with no errors when I refresh the page.

    I’m not a developer – mostly just learning by searching, so I’m not really sure where to start looking for the solution (none of the support topics already published seemed like they were similar issues). Any help would be appreciated. Thanks!

    Jessica

    Sample Console error message:

    Uncaught TypeError: qodefPortfolioFullScreenSlider is not a function
    at HTMLDocument.<anonymous> (autoptimize_a5184aa579ef8ef443ede497c184e031.js:1678)
    at i (jquery.js?ver=1.12.4:2)
    at Object.add [as done] (jquery.js?ver=1.12.4:2)
    at a.fn.init.n.fn.ready (jquery.js?ver=1.12.4:2)
    at autoptimize_a5184aa579ef8ef443ede497c184e031.js:1673

    Second sample from a different page on my site:

    autoptimize_08d52e66d2bd59f180bfd30897832d30.js:147 Uncaught TypeError: wpcf7.initForm is not a function
    at HTMLFormElement.<anonymous> (autoptimize_08d52e66d2bd59f180bfd30897832d30.js:147)
    at Function.each (jquery.js?ver=1.12.4:2)
    at a.fn.init.each (jquery.js?ver=1.12.4:2)
    at HTMLDocument.<anonymous> (autoptimize_08d52e66d2bd59f180bfd30897832d30.js:147)
    at i (jquery.js?ver=1.12.4:2)
    at Object.add [as done] (jquery.js?ver=1.12.4:2)
    at n.fn.init.n.fn.ready (jquery.js?ver=1.12.4:2)
    at a.fn.init.n.fn.init (jquery.js?ver=1.12.4:2)
    at new a.fn.init (autoptimize_08d52e66d2bd59f180bfd30897832d30.js:6)
    at n (jquery.js?ver=1.12.4:2)

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    Hmmm, hard to say, but often when problems are random-ish like this it is due the use of async or defer on scripts that should not be asynced or deferred. you seem to be using “async javascript” (and maybe some other things), can you disable those for starters?

    frank

    Thread Starter jesshamm312

    (@jesshamm312)

    Hi Frank,

    Thanks for your help. Yes, I was using Async Javascript plugin. I was given to believe that it usually works will with Autoptimize, but I disabled the plugin and now it seems to be working fine with no errors.

    Originally I used the Async Javascript wizard to implement the recommended settings (async on javascript, defer on jquery) and followed the instructions to integrate the two plugins. So, should I not use Async Javascript at all if I want to use Autoptimize or do I do some trial and error to figure out if different settings work better or if there are scripts that shouldn’t be deferred or asynced?

    Where would you go next with this? Thanks for your help!

    Jessica

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    You might be able to get AO & AsyncJS working together by tweaking settings, but I would only do that if that combination offers tangible performance advantages (as in; your page loading faster as per tests on https://webpagetest.org) 🙂

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

The topic ‘Uncaught type errors that disappear on page refresh’ is closed to new replies.