[Resolved] Mobile menu not working

Home Forums Support [Resolved] Mobile menu not working

Home Forums Support Mobile menu not working

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #2360286
    Zoltan

    Hi there,

    I am using the dispatch GP premium theme and the mobile dropdown menu is not working on mobile.

    Currently, the only time the mobile menu is visible and works are after I am doing a search for any random term in the mobile search bar.

    Desktop is fine, the only issue is on mobile.

    Can you please take a look?

    Thanks,

    Zoltan

    #2360706
    Leo
    Staff
    Customer Support

    Hi there,

    Any chance you can disable all plugins except GP Premium to eliminate conflicts from other plugins first?

    Let me know 🙂

    #2360716
    Zoltan

    Hi there,

    I disabled all the plugins one by one while checking if the mobile menu works.

    Can confirm this was most likely caused by the Litespeed cache – “Load Javascript Deferred” setting turned on.

    I am sure this was the cause because I have another site with the same theme and settings, also same Litespeed cache settings, except Javascript deferred off (because the other site is not running ads, so does not need JS deferred)

    Do you know any workarounds for this, please?

    The reason I need to have javascript deferred is to improve loading speed and core web vitals when running ads javascript on every page. But it will break the GP mobile menu on the premium Dispatch theme.

    Please let me know.

    Thanks!

    #2360717
    Zoltan

    To clarify now that I turned off Javascript delayed, the mobile menu works like a charm.

    #2360719
    Leo
    Staff
    Customer Support

    Does it allow you to exclude some scripts?

    #2360745
    Zoltan

    Yes, it does allow to exclude JS: “Listed JS files or inline JS code will not be deferred. Both full URLs and partial strings can be used.”

    #2360778
    Leo
    Staff
    Customer Support

    Can you check with LiteSpeed’s support team to see if there is a way to exclude all files from generatepress and gp-premium folder?

    #2360792
    Zoltan

    I will check, thanks!

    #2360802
    Leo
    Staff
    Customer Support

    Sounds good. Let me know.

    I’ll keep this topic open.

    #2360827
    Zoltan

    So the mobile menu now works on both of my Dispatch theme LiteSpeed cached sites, if JS is deferred.

    If JS is delayed (this was causing the frontend issue) then the Dispatch mobile menu stops working.

    As a quick fix, I changed the setting to JS deferred. It appears Litespeed does not have an option to exclude JS delay scripts only can exclude JS defer scripts.

    Thanks, Leo this should work fine now.

    #2360829
    Leo
    Staff
    Customer Support

    Thanks for sharing the result!

Viewing 11 posts - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.