This isn’t unique to jQuery, but an aspect of javascript. All functions are objects. E.g.:
var f = function() { alert('yo'); }
f.foo = "bar";
alert(f.foo); // alerts "bar"
f(); // alerts "yo"
More Related Contents:
- Adding The Anchor Text As The Title Dynamicaly
- Get all Attributes from a HTML element with Javascript/jQuery
- How to prevent a click on a ‘#’ link from jumping to top of page?
- How to disable scroll without hiding it?
- Resize jqGrid when browser is resized?
- Selecting multiple classes with jQuery
- Passing data to a jQuery UI Dialog
- jQuery add required to input fields
- document.getElementsByClassName().innerHTML always returns “undefined”
- jQuery jump or scroll to certain position, div or target on the page from button onclick [duplicate]
- JavaScript: Invert color on all elements of a page
- Failed to load resource: net::ERR_CONTENT_LENGTH_MISMATCH
- how can I override console.log() and prepend a word at the beginning of the output?
- How to create rounded bars for Bar Chart.js v2?
- jQuery support “:invalid” selector
- How to individually target multiple dropdowns in CSS for Dropkick Plug-in
- combo box is getting vanished when an alert is coming
- Clone a file input element in Javascript
- jQuery vs. javascript? [closed]
- submit event does not fire if submit initiated programmatically
- jQuery plugin DataTables: How to highlight the current search text?
- Add CSS rule via jQuery for future created elements
- jQuery continuous mousedown
- closure inside a for loop – callback with loop variable as parameter [duplicate]
- minimise the code since I am using the same code only the content in p tags changes and component AccordionHeader header changes
- Rotate div text after clicking on button using jquery and css
- let user scrolling stop jquery animation of scrolltop?
- Hot to get incomplete datetime-local input values
- Content of html page changed by jQuery but “View Source” don’t reflect the changes
- jQuery: Count words in real time