What are the main differences between jQuery 3 and jQuery 4?

<p>Page</p>
console.log('$.trim: ' + typeof $.trim);
console.log('$.isArray: ' + typeof $.isArray);
console.log('$.parseJSON: ' + typeof $.parseJSON);
Result in jQuery 3.7.1 and in 4.0.0

jQuery 3.7.1:
$.trim: function
$.isArray: function
$.parseJSON: function

jQuery 4.0.0:
$.trim: undefined
$.isArray: undefined
$.parseJSON: undefined

Use the native JavaScript versions to make the code work in both. See jQuery 4 and Upgrading.


Learn more about the similar topics:
Tutorials
No Content Found.
Exercises & Assignments
No Content Found.
Interview Questions & Answers
No Content Found.