WordPress SEO by Yoast
[resolved] WP SEO hijacking jquery enqueing (5 posts)

  1. aljuk
    Posted 2 years ago #

    I use a custom function to enqueue a specific jquery version direct from the cdn with a local fallback.

    When WP SEO is enabled, the enqueue gets hijacked and the jquery library is pulled from wp-includes.

    How can I disable this behaviour?


  2. SpaceDragon
    Posted 1 year ago #

    +1 on this question. Unsure why WordPress SEO is loading on the front end since it seems to only be used in the admin area to control tabs. Looking to exclusively run jQuery 1.9.1 but WordPress SEO is also pulling 1.7.1… and not from wp-includes but from Google's CDN.

  3. jrf
    Posted 1 year ago #

    There's an outstanding discussion already to change this behaviour. Fingers crossed it will result in the code changes soon.

    In that respect @aljuk - you're doing the same thing, bad practice in both cases.

  4. aljuk
    Posted 1 year ago #

    "In that respect @aljuk - you're doing the same thing, bad practice in both cases."

    I'm "doing the same thing"? Hmm... Last time I checked I hadn't designed any plugins that forced old, locally hosted versions of jquery on a website. Or you think it's "bad practice" to deliver popular scripts from a cdn?

    Far from "bad practice", I think you'll find I'm using "best practice".

  5. jrf
    Posted 1 year ago #

    Sorry, I misunderstood. I though it was part of code you intended to share/are sharing as a plugin/theme.

    If you only use it for your own site, it's up to you to decide how you want to hosts the scripts used.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WordPress SEO by Yoast
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.