$this vs $(this) in jQuery

后端 未结 15 798
北恋
北恋 2020-11-29 18:07

I\'ve seen some discussions on SO regarding $(this) vs $this in jQuery, and they make sense to me. (See discussion here for an example.)

Bu

15条回答
  •  孤独总比滥情好
    2020-11-29 18:16

    $this is just a local copy of this wrapped in jQuery.

    In the long term, keeping a local copy rather than wrapping this each time it is needed is much more efficient.

提交回复
热议问题