siesta-lite
Version:
Stress-free JavaScript unit testing and functional testing tool, works in NodeJS and browsers
24 lines (19 loc) • 593 B
JavaScript
/*
Siesta 5.6.1
Copyright(c) 2009-2022 Bryntum AB
https://bryntum.com/contact
https://bryntum.com/products/siesta/license
*/
Role('Siesta.Util.Role.CanGetType', {
methods : {
/**
* This method returns a result of `Object.prototype.toString` applied to the passed argument. The `[object` and trailing `]` are trimmed.
*
* @param {Mixed} object
* @return {String} The name of the "type" for this object.
*/
typeOf : function(object) {
return Object.prototype.toString.call(object).slice(8, -1);
}
}
})