console.table
Advanced tools
Comparing version 0.7.0 to 0.8.0
@@ -1,1 +0,1 @@ | ||
!function(){"use strict";function a(){function a(a,b){return typeof b===a}function b(a,b){return Array.isArray(b)&&b.every(a)}function c(a){var b=new k;return a.forEach(function(a){"string"==typeof a||"number"==typeof a?b.cell("item",a):Object.keys(a).forEach(function(c){b.cell(c,a[c])}),b.newRow()}),b.toString()}function d(a,b){var c=new k;b.forEach(function(b){b.forEach(function(b,d){c.cell(a[d],b)}),c.newRow()});var d=c.toString();console.log(d)}function e(a,b){var d=c(b),e=d.indexOf("\n");if(e>0){a.length>e&&(e=a.length),console.log(a);var f,g="-",h="";for(f=0;e>f;f+=1)h+=g;console.log(h)}console.log(d)}function f(a){var b=Object.keys(a);return b.map(function(b){return{key:b,value:a[b]}})}function g(a){return c(f(a))}if("undefined"==typeof console)throw new Error("Weird, console object is undefined");if("function"!=typeof console.table){var h=a.bind(null,"string"),i=b.bind(null,h),j=b.bind(null,Array.isArray),k=require("easy-table");console.table=function(){var a=Array.prototype.slice.call(arguments);return 2===a.length&&"string"==typeof a[0]&&Array.isArray(a[1])?e(a[0],a[1]):2===a.length&&i(a[0])&&j(a[1])?d(a[0],a[1]):void a.forEach(function(a){return"string"==typeof a?console.log(a):void(Array.isArray(a)?console.log(c(a)):"object"==typeof a&&console.log(g(a)))})}}}a()}(); | ||
!function(){"use strict";function a(){function a(a,b){return typeof b===a}function b(a,b){return Array.isArray(b)&&b.every(a)}function c(a){var b=new k;return a.forEach(function(a){"string"==typeof a||"number"==typeof a?b.cell("item",a):Object.keys(a).forEach(function(c){b.cell(c,a[c])}),b.newRow()}),b.toString()}function d(a,b){var c=new k;b.forEach(function(b){b.forEach(function(b,d){c.cell(a[d],b)}),c.newRow()});var d=c.toString();console.log(d)}function e(a,b){var d=c(b),e=d.indexOf("\n");if(e>0){a.length>e&&(e=a.length),console.log(a);var f,g="-",h="";for(f=0;f<e;f+=1)h+=g;console.log(h)}console.log(d)}function f(a){var b=Object.keys(a);return b.map(function(b){return{key:b,value:a[b]}})}function g(a){return c(f(a))}if("undefined"==typeof console)throw new Error("Weird, console object is undefined");if("function"!=typeof console.table){var h=a.bind(null,"string"),i=b.bind(null,h),j=b.bind(null,Array.isArray),k=require("easy-table");console.table=function(){var a=Array.prototype.slice.call(arguments);return 2===a.length&&"string"==typeof a[0]&&Array.isArray(a[1])?e(a[0],a[1]):2===a.length&&i(a[0])&&j(a[1])?d(a[0],a[1]):void a.forEach(function(a){return"string"==typeof a?console.log(a):void(Array.isArray(a)?console.log(c(a)):"object"==typeof a&&console.log(g(a)))})}}}a()}(); |
{ | ||
"name": "console.table", | ||
"description": "Adds console.table method that prints an array of objects as a table in console", | ||
"version": "0.7.0", | ||
"version": "0.8.0", | ||
"author": "Gleb Bahmutov <gleb.bahmutov@gmail.com>", | ||
@@ -23,3 +23,3 @@ "bugs": { | ||
"dependencies": { | ||
"easy-table": "0.3.0" | ||
"easy-table": "1.0.0" | ||
}, | ||
@@ -41,3 +41,3 @@ "devDependencies": { | ||
"grunt-mocha-test": "0.12.7", | ||
"grunt-nice-package": "0.10.2", | ||
"grunt-nice-package": "0.10.3", | ||
"grunt-npm2bower-sync": "0.8.1", | ||
@@ -44,0 +44,0 @@ "matchdep": "0.3.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
15146
7
0
153
+ Addedeasy-table@1.0.0(transitive)
- Removedeasy-table@0.3.0(transitive)
Updatedeasy-table@1.0.0