在下面例子中為什么在PageSwitch中又定義了名為PageSwitch的函數(shù)var PageSwitch = (function () {? ? ? ? function PageSwitch(element, options) {? ? ? ? ? ? // deep copy? ? ? ? ? ? this.settings = $.extend(true, $.fn.PageSwitch.defaults, options || {});? ? ? ? ? ? this.element = element;? ? ? ? ? ? this.init();? ? ? ? }})
var PageSwitch = (function () {})這種寫法是什么意思啊
momoyy123
2016-06-13 17:55:53