Today, when we study the source code, we find that it is not necessary to use get () to convert natively, using native methods.
Native-jquery Object
var obj=document.xxx
$ (obj). css ();
You can also direct $ (document.xxx)
jquery objects-Native
Method one: Get ()
$ (' Li '). get ();
Is that it? The set of elements acquired by JQ is converted to a native object, and a get () parameter can also be used to represent the one that is currently being converted, which can be a native method.
Many ask the difference between EQ () and get ():
It's easy, you use EQ () and then you can't use the native method, followed by the JQ method.
$ (' input '). EQ (1). css (' background ', ' blue ')
Instead, using get (), you can only use the native method
$ (' input '). Get (1). Style.background (' Blue ')
Method Two: Direct use subscript, that is to say there are some cases you can save get (), two directly can use the native method to accomplish what you want to do, it is not more convenient
Test 1: Looping
Test 2: Form
Test 3: After the subscript is added, the method of using JQ will error
JQuery-how native to each other