3

JQMIGRATE: jQuery.fn.andSelf() replaced by jQuery.fn.addBack() error when first time lode the website after refreshing all ok every thing are working its in magento 2.2.6

please not provide solution like

marge js and css

than static:content:deploy command run

like that

  • Have you got the answer of your query? – Muhammad Hasham Apr 22 at 7:19
0

jQuery Migrate's warning about andSelf() is a bit early. It was not removed in jQuery 1.8 or any other version. It is still supported in jQuery 1.11 (latest) and 2.x.

So this isn't a perquisite for the current migration cycle of jQuery. jQuery UI chooses to continue using andSelf instead of addBack so that it is compatible with both old and new jQuery versions. If and when jQuery core removes andSelf, jQuery UI will likely use feature detection and thus no longer trigger this warning.

Cause: The .andSelf() method has been renamed to .addBack() as of jQuery 1.9 to better reflect its purpose of adding back the previous set of results. The old alias was removed in jQuery 3.0.

Still you want to remove this warning.

Solution: Replace any use of .andSelf() with .addBack().

Reference: https://github.com/jquery/jquery-migrate/blob/master/warnings.md

I hope this will help

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.