Wednesday, 24 August 2016
Removed jQuery .ready(handler) from version jQuery 3.0
Initially jquery introduces $( document ).ready( handler ). After that there some more events were introduced but currently from jquery version 3.0 only one handler works perfectly i.e., $( handler ).
Different types to attach a function to ready event :
Example :
$(function(){
//Your code
});
Different types to attach a function to ready event :
- $( handler )
- $( document ).ready( handler )
- $( "document" ).ready( handler ) // Removed in jquery 3.0 version
- $( "img" ).ready( handler )
- $().ready( handler )
Example :
$(function(){
//Your code
});
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment