Comparing version 0.9.1 to 1.0.0
{ | ||
"name": "typeof", | ||
"version": "0.9.1", | ||
"description": "Node module. typeOf('a string') == 'string', typeOf([]) == 'array', etc..", | ||
"version": "1.0.0", | ||
"description": "Node module. typeOf('a string') == 'string', typeOf([]) == 'array', etc.. Also supports named functions detections aka javascript classes", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "./node_modules/mocha/bin/mocha -R spec --compilers coffee:coffee-script test.coffee" | ||
"test": "mocha -R spec --compilers coffee:coffee-script test.coffee" | ||
}, | ||
@@ -19,3 +19,4 @@ "repository": { | ||
"license": "MIT", | ||
"dependencies": { | ||
"dependencies": {}, | ||
"devDependencies": { | ||
"coffee-script": "~1.4.0", | ||
@@ -22,0 +23,0 @@ "mocha": "~1.6.0", |
# typeof | ||
small node.js module that extends functionality of native typeof | ||
inspired by Batman.js typeOf util | ||
**-------------------------------** | ||
**UPD:** now it returns lowercased name of any javascript class. | ||
Small node.js module that dramatically extends functionality of native typeof | ||
Inspired by Batman.js typeOf util | ||
**UPD:** now it returns lowercased name of any javascript class. Thanks to @BallBearing for idea | ||
## Usage: | ||
@@ -18,5 +19,12 @@ | ||
console.log(typeOf("a string")); | ||
// -> "string" | ||
console.log(typeOf([1, 2, 3, "array"])); | ||
// -> "array" | ||
console.log(typeOf(null)); | ||
// -> "null" | ||
console.log(typeOf(new Buffer(0))); | ||
// -> "buffer" | ||
@@ -27,10 +35,3 @@ function MyClass() { | ||
console.log(typeOf(new MyClass)); | ||
// ->"myclass" | ||
``` | ||
``` | ||
"string" | ||
"array" | ||
"null" | ||
"buffer" | ||
"myclass" | ||
``` |
Sorry, the diff of this file is not supported yet
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
4001
0
6
1
36
0
3
- Removedassert@~0.4.9
- Removedcoffee-script@~1.4.0
- Removedmocha@~1.6.0
- Removedassert@0.4.9(transitive)
- Removedavailable-typed-arrays@1.0.7(transitive)
- Removedcall-bind@1.0.8(transitive)
- Removedcall-bind-apply-helpers@1.0.2(transitive)
- Removedcall-bound@1.0.3(transitive)
- Removedcoffee-script@1.4.0(transitive)
- Removedcommander@0.6.1(transitive)
- Removeddebug@4.4.0(transitive)
- Removeddefine-data-property@1.1.4(transitive)
- Removeddiff@1.0.2(transitive)
- Removeddunder-proto@1.0.1(transitive)
- Removedes-define-property@1.0.1(transitive)
- Removedes-errors@1.3.0(transitive)
- Removedes-object-atoms@1.1.1(transitive)
- Removedfor-each@0.3.5(transitive)
- Removedfunction-bind@1.1.2(transitive)
- Removedget-intrinsic@1.3.0(transitive)
- Removedget-proto@1.0.1(transitive)
- Removedgopd@1.2.0(transitive)
- Removedgrowl@1.5.1(transitive)
- Removedhas-property-descriptors@1.0.2(transitive)
- Removedhas-symbols@1.1.0(transitive)
- Removedhas-tostringtag@1.0.2(transitive)
- Removedhasown@2.0.2(transitive)
- Removedinherits@2.0.4(transitive)
- Removedis-arguments@1.2.0(transitive)
- Removedis-callable@1.2.7(transitive)
- Removedis-generator-function@1.1.0(transitive)
- Removedis-regex@1.2.1(transitive)
- Removedis-typed-array@1.1.15(transitive)
- Removedjade@0.26.3(transitive)
- Removedmath-intrinsics@1.1.0(transitive)
- Removedmkdirp@0.3.00.3.3(transitive)
- Removedmocha@1.6.0(transitive)
- Removedms@0.3.02.1.3(transitive)
- Removedpossible-typed-array-names@1.1.0(transitive)
- Removedsafe-regex-test@1.1.0(transitive)
- Removedset-function-length@1.2.2(transitive)
- Removedutil@0.12.5(transitive)
- Removedwhich-typed-array@1.1.18(transitive)