jQuery error bug?
-
Seems to work once jQuery Migrate is checked. Is it on or off then? Not sure and might be confusing. On/Off should be On = not checked Off = Checked? if so it works once migrate is off. Also think Assets cleanup is disabling it might be a conflict there if both isn’t checked to unload.
But once checked I can see “JQMIGRATE: Migrate is installed, version 3.1.0” so that means it is not unloaded.
Hi @alriksson
By default both are activated when you activate the plugin.
And both the latest stable version.Maybe you have an aggressive caching / minify plugin?
The way it should work is very simple, if it’s checked on then it’s activated.
Kind regards,
RemziUsing WP Rocket at the moment and I seem to be forced to load migrate otherwise I face this console error. I do not want to load the Migrate since it is not needed.
Could you exclude this plugin? (usually it’s an loading order issue) I think you have priority support, I would recommend to open a ticket at WP Rocket.
@remzicavdar I do and they recommended me to contact the developer of the plugin which is you. If I disable the output of jQuery Migrate it shouldn’t matter but it does, unfortuently.
Hi @alriksson
I know what the problem is jQuery itself is being deferred, not all plugins and/or themes support this. Also after turning off jQuery MIgrate, try to clean/destroy your cache and everything from WP Rocket.
WP Rocket does aggressive caching (which is good), preloading, Defer JS Loading and other good things. You will need to Clear WP Rocket Cache after changing settings in jQuery manager, see: https://docs.wp-rocket.me/article/53-clear-wp-rocket-cache
Also my apologies for my late reaction this happened due to working constraints and different time zones. I always try to answer within 48 hours.
Let me know when you have solved your issue.
Kind regards,
RemziHave tried this even disabled defer js in wp rocket. Without success so still stuck with loading the migrate to not face any console errors.
No worry ??
Hi @alriksson
Could you disabled the plug-in and check if everything works? I would like to exclude the possibility that it’s WP Rocket.
Regards,
RemziPS: By disabling, I mean disable the jQuery Manager for WordPress plugin and check if everything works again.
I think the order of minifying and bundling is going wrong, jQuery.Deferred exception usually happens the order of your script is not right.
This can happen if WP Rocket minifies, bundles and makes one script from all of them. Try to adjust the order, or exclude jQuery and/or some other settings from WP Rocket. See similar issue https://stackoverflow.com/questions/41951517/jquery-deferred-exception-datepicker-is-not-a-function/52058912
I hope you’re able to solve this issue, otherwise I’m willing to talk directly with WP Rocket on your behalf.
Regards,
RemziMight be a conflict with the main jQuery as well. Since in your plugin it is set to default and wp rocket defer it. Could it be a conflict here as well since I experience some jquery issue when defer in wp rocket.
Above seems to various of jquery even inline. Think this is more on wp rockets side though.
Added a new support request for wp rocket to check as well.
I can put all 3 parties in a email chain which might make it easier for everyone. Even share staging environment which I wont do over the public wp support thread.
Also found out that the migrate seems to work to disable on apache or apache nginx reverse but not on nginx alone.
@alriksson I definitely think it’s about the script order. jQuery needs to be loaded first or before the script which uses jQuery.
I think you should tell WP Rocket and ask how to change the script order or how to load something first.
Hi @alriksson
Did you talked/mailed with WP Rocket?
I could contact them directly if prefer that, because I understand what the problem is, it’s more like a configuration issue on your end, but it’s still annoying that this occurs.Maybe I can work something out with WP Rocket, so that other users will have better support and/or that the plugin automatically configures or use pre-applied settings.
Kind regards,
RemziPS: If you’re not sure about something , you could also enable debugging settings. Then you will get a detailed view about what’s happening in the background.
- This reply was modified 4 years, 12 months ago by Remzi Cavdar.
@remzicavdar Sorry for late reply!
Please do, there is not too much of configurations when it comes to defer in WP Rocket. Safe mode or nto safe mode which is excluding or including jQuery.
Sounds great Remzi!
Hi @alriksson
I have sent them a message.
Could you also try these things:
– https://docs.wp-rocket.me/article/19-resolving-issues-with-file-optimization
– https://docs.wp-rocket.me/article/19-resolving-issues-with-file-optimization#combine-css-jsIn the meantime this is all I can do for you.
I will get back to you asap when I get an reply from WP Rocket.Regards,
Remzi@remzicavdar Thanks, tried excluding files I think could cause it. But preferably should work but as you say it may be the wrong ordering of the scripts.
- The topic ‘jQuery error bug?’ is closed to new replies.