Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cnbuilder

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cnbuilder - npm Package Compare versions

Comparing version 1.0.8 to 1.0.9

73

dist/cnbuilder.esm.js

@@ -1,31 +0,48 @@

const cnb = function cnb(...args) {
return ((args.length
? args.length > 1
? args.reduce(arrayReducer, "")
: arrayReducer("", args[0])
: ""));
function _typeof(obj) {
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
_typeof = function (obj) {
return typeof obj;
};
} else {
_typeof = function (obj) {
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
};
}
return _typeof(obj);
}
var cnb = function cnb() {
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
return args.length ? args.length > 1 ? args.reduce(arrayReducer, "") : arrayReducer("", args[0]) : "";
};
const arrayReducer = (result, item) => {
let type = typeof item;
if (type === "string") {
return item ? result + (result && " ") + item : result;
var arrayReducer = function arrayReducer(result, item) {
var type = _typeof(item);
if (type === "string") {
return item ? result + (result && " ") + item : result;
}
if (Array.isArray(item)) {
var tmp = item.length ? item.length > 1 ? item.reduce(arrayReducer, "") : arrayReducer("", item[0]) : "";
return tmp ? result + (result && " ") + tmp : result;
}
if (type === "object" && item) {
var _tmp = "";
for (var i in item) {
if (item[i] && item.hasOwnProperty(i)) {
_tmp += (_tmp && " ") + i;
}
}
if (Array.isArray(item)) {
let tmp = item.length
? item.length > 1
? item.reduce(arrayReducer, "")
: arrayReducer("", item[0])
: "";
return tmp ? result + (result && " ") + tmp : result;
}
if (type === "object" && item) {
let tmp = "";
for (let i in item) {
if (item[i] && item.hasOwnProperty(i)) {
tmp += (tmp && " ") + i;
}
}
return tmp ? result + (result && " ") + tmp : result;
}
return result;
return _tmp ? result + (result && " ") + _tmp : result;
}
return result;
};

@@ -32,0 +49,0 @@

@@ -1,2 +0,2 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).cnbuilder={})}(this,function(e){"use strict";const t=function(...e){return e.length?e.length>1?e.reduce(n,""):n("",e[0]):""},n=(e,t)=>{let r=typeof t;if("string"===r)return t?e+(e&&" ")+t:e;if(Array.isArray(t)){let r=t.length?t.length>1?t.reduce(n,""):n("",t[0]):"";return r?e+(e&&" ")+r:e}if("object"===r&&t){let n="";for(let e in t)t[e]&&t.hasOwnProperty(e)&&(n+=(n&&" ")+e);return n?e+(e&&" ")+n:e}return e};e.cnb=t,e.default=t});
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).cnbuilder={})}(this,function(t){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var n=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return e.length?e.length>1?e.reduce(r,""):r("",e[0]):""},r=function t(n,r){var o=e(r);if("string"===o)return r?n+(n&&" ")+r:n;if(Array.isArray(r)){var f=r.length?r.length>1?r.reduce(t,""):t("",r[0]):"";return f?n+(n&&" ")+f:n}if("object"===o&&r){var u="";for(var i in r)r[i]&&r.hasOwnProperty(i)&&(u+=(u&&" ")+i);return u?n+(n&&" ")+u:n}return n};t.cnb=n,t.default=n});
//# sourceMappingURL=cnbuilder.js.map
{
"name": "cnbuilder",
"version": "1.0.8",
"version": "1.0.9",
"main": "dist/cnbuilder.js",

@@ -32,2 +32,4 @@ "module": "dist/cnbuilder.esm.js",

"devDependencies": {
"@babel/core": "^7.4.0",
"@babel/preset-env": "^7.4.2",
"@types/jest": "^24.0.9",

@@ -41,2 +43,3 @@ "codacy-coverage": "^3.4.0",

"rollup": "^1.3.2",
"rollup-plugin-babel": "^4.3.2",
"rollup-plugin-typescript2": "^0.19.3",

@@ -43,0 +46,0 @@ "terser": "^3.16.1",

Sorry, the diff of this file is not supported yet

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