Skip to content

Instantly share code, notes, and snippets.

@natevenn
Created May 7, 2016 02:12
Show Gist options
  • Select an option

  • Save natevenn/0fe2b531364c8357dc5e4ae144ef6e41 to your computer and use it in GitHub Desktop.

Select an option

Save natevenn/0fe2b531364c8357dc5e4ae144ef6e41 to your computer and use it in GitHub Desktop.
use $(document).ready() to ensure the page is ready to be manipulated.
.ready() can take arg such a functions
$('some element') creates a js object that you can do something with or manipulate in some way
note that you must create a js object of a dom element to call jquery methods on it
the methods you can call on these objects are either getters or setters
getters gets info on the selection
setters alter the selection
Chaining is possible because every setter method in jQuery returns the selection on which it was called
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment