MCPcopy
hub / github.com/onokumus/metismenu / Plugin

Function Plugin

src/metisMenu.js:260–277  ·  view source on GitHub ↗
(option)

Source from the content-addressed store, hash-verified

258 };
259
260 function Plugin(option) {
261 return this.each(function() {
262 var $this = $(this);
263 var data = $this.data('mm');
264 var options = $.extend({},
265 MetisMenu.DEFAULTS,
266 $this.data(),
267 typeof option === 'object' && option
268 );
269
270 if (!data) {
271 $this.data('mm', (data = new MetisMenu(this, options)));
272 }
273 if (typeof option === 'string') {
274 data[option]();
275 }
276 });
277 }
278
279 var old = $.fn.metisMenu;
280

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected