New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ezzy-typeof

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ezzy-typeof - npm Package Compare versions

Comparing version 0.0.1 to 0.1.10

README.md

36

index.js

@@ -1,35 +0,1 @@

/*!
* Copyright (c) 2016 Moises Romero
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
/**
* Obtains the true type name of any object
*
* @param {*} obj The element you need the type of
* @param {string} [isType] The type to compare it to (returns boolean response)
* @returns {string|boolean}
*/
module.exports = (obj, isType) => {
let type = ({})
.toString
.call(obj)
.match(/\s([a-zA-Z]+)/)[1]
.toLowerCase();
return isType ? type == isType : type;
};
module.exports = require('./src/trueTypeOf');
{
"name": "ezzy-typeof",
"version": "0.0.1",
"description": "A true javascript typeof",
"description": "A lightweight package to indicate the true value of an object.",
"version": "0.1.10",
"author": {
"name": "Moises Romero",
"url": "http://ezzygemini.com",
"email": "ezzygemini@gmail.com"
},
"repository": {
"type": "git",
"url": "git@github.com:ezzygemini/typeof.git"
"url": "https://github.com/ezzygemini/ezzy-typeof.git"
},
"scripts": {
"test": "node node_modules/ezzy-testing"
},
"license": "MIT",
"devDependencies": {
"ezzy-testing": "^0.1.2"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc