Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download
80538 views
1
var supportsArgumentsClass = (function(){
2
return Object.prototype.toString.call(arguments)
3
})() == '[object Arguments]';
4
5
exports = module.exports = supportsArgumentsClass ? supported : unsupported;
6
7
exports.supported = supported;
8
function supported(object) {
9
return Object.prototype.toString.call(object) == '[object Arguments]';
10
};
11
12
exports.unsupported = unsupported;
13
function unsupported(object){
14
return object &&
15
typeof object == 'object' &&
16
typeof object.length == 'number' &&
17
Object.prototype.hasOwnProperty.call(object, 'callee') &&
18
!Object.prototype.propertyIsEnumerable.call(object, 'callee') ||
19
false;
20
};
21
22