Mercurial > nebulaweb3
annotate default/node_modules/jquery/src/var/isFunction.js @ 0:1d038bc9b3d2 default tip
Up:default
author | Liny <dev@neowd.com> |
---|---|
date | Sat, 31 May 2025 09:21:51 +0800 |
parents | |
children |
rev | line source |
---|---|
0 | 1 define( function() { |
2 "use strict"; | |
3 | |
4 return function isFunction( obj ) { | |
5 | |
6 // Support: Chrome <=57, Firefox <=52 | |
7 // In some browsers, typeof returns "function" for HTML <object> elements | |
8 // (i.e., `typeof document.createElement( "object" ) === "function"`). | |
9 // We don't want to classify *any* DOM node as a function. | |
10 return typeof obj === "function" && typeof obj.nodeType !== "number"; | |
11 }; | |
12 | |
13 } ); |