@blackglory/log
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -637,3 +637,3 @@ (function (global, factory) { | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -674,3 +674,3 @@ }; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -677,0 +677,0 @@ }); |
@@ -16,3 +16,3 @@ !function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((n="undefined"!=typeof globalThis?globalThis:n||self).Log={})}(this,(function(n){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},i={},e={};function r(n){return Array.isArray(n)}e.isntEmptyArray=e.isEmptyArray=e.isntArray=e.isArray=void 0,e.isArray=r,e.isntArray=function(n){return!r(n)},e.isEmptyArray=function(n){return 0===n.length},e.isntEmptyArray=function(n){return 0!==n.length};var o={},u={};function s(n){return null===n}u.isntNull=u.isNull=void 0,u.isNull=s,u.isntNull=function(n){return!s(n)};var c={};function f(n){return void 0===n}c.isntUndefined=c.isUndefined=void 0,c.isUndefined=f,c.isntUndefined=function(n){return!f(n)};var a={};function l(n){return"function"==typeof n}a.isntFunction=a.isFunction=void 0,a.isFunction=l,a.isntFunction=function(n){return!l(n)},o.isntAsyncIterable=o.isAsyncIterable=void 0;const b=u,y=c,d=a;function v(n){return(0,b.isntNull)(n)&&(0,y.isntUndefined)(n)&&(0,d.isFunction)(n[Symbol.asyncIterator])}o.isAsyncIterable=v,o.isntAsyncIterable=function(n){return!v(n)};var p={};function g(n){return"bigint"==typeof n}p.isntBigInt=p.isBigInt=void 0,p.isBigInt=g,p.isntBigInt=function(n){return!g(n)};var j={};function m(n){return"boolean"==typeof n}j.isntBoolean=j.isBoolean=void 0,j.isBoolean=m,j.isntBoolean=function(n){return!m(n)};var O={},h={};function N(n){return"string"==typeof n}h.isntString=h.isString=void 0,h.isString=N,h.isntString=function(n){return!N(n)},O.isntChar=O.isChar=void 0;const P=h;function w(n){return(0,P.isString)(n)&&1===n.length}O.isChar=w,O.isntChar=function(n){return!w(n)};var A={};function F(n){return n instanceof Date}A.isntDate=A.isDate=void 0,A.isDate=F,A.isntDate=function(n){return!F(n)};var I={};I.inEnum=void 0,I.inEnum=function(n,t){return Object.values(t).includes(n)};var S={};function E(n){return n instanceof Error}S.isntError=S.isError=void 0,S.isError=E,S.isntError=function(n){return!E(n)};var D={};function _(n){return!n}D.isntFalsy=D.isFalsy=void 0,D.isFalsy=_,D.isntFalsy=function(n){return!_(n)};var B={};B.isntIterable=B.isIterable=void 0;const U=u,J=c,L=a;function k(n){return(0,U.isntNull)(n)&&(0,J.isntUndefined)(n)&&(0,L.isFunction)(n[Symbol.iterator])}B.isIterable=k,B.isntIterable=function(n){return!k(n)};var x={},T={};function C(n){return"number"==typeof n}function M(n){return Number.isNaN(n)}T.isntNaN=T.isNaN=T.isNegativeInfinity=T.isPositiveInfinity=T.isFinite=T.isntNumber=T.isNumber=void 0,T.isNumber=C,T.isntNumber=function(n){return!C(n)},T.isFinite=function(n){return Number.isFinite(n)},T.isPositiveInfinity=function(n){return n===1/0},T.isNegativeInfinity=function(n){return n===-1/0},T.isNaN=M,T.isntNaN=function(n){return!M(n)};var R={},q="object"==typeof t&&t&&t.Object===Object&&t,z="object"==typeof self&&self&&self.Object===Object&&self,G=(q||z||Function("return this")()).Symbol,H=G,K=Object.prototype,Q=K.hasOwnProperty,V=K.toString,W=H?H.toStringTag:void 0;var X=function(n){var t=Q.call(n,W),i=n[W];try{n[W]=void 0;var e=!0}catch(n){}var r=V.call(n);return e&&(t?n[W]=i:delete n[W]),r},Y=Object.prototype.toString;var Z=X,$=function(n){return Y.call(n)},nn=G?G.toStringTag:void 0;var tn=function(n){return null==n?void 0===n?"[object Undefined]":"[object Null]":nn&&nn in Object(n)?Z(n):$(n)};var en=function(n,t){return function(i){return n(t(i))}}(Object.getPrototypeOf,Object);var rn=tn,on=en,un=function(n){return null!=n&&"object"==typeof n},sn=Function.prototype,cn=Object.prototype,fn=sn.toString,an=cn.hasOwnProperty,ln=fn.call(Object);var bn=function(n){if(!un(n)||"[object Object]"!=rn(n))return!1;var t=on(n);if(null===t)return!0;var i=an.call(t,"constructor")&&t.constructor;return"function"==typeof i&&i instanceof i&&fn.call(i)==ln},yn=t&&t.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};R.isntEmptyObject=R.isEmptyObject=R.isntPlainObject=R.isPlainObject=R.isntObject=R.isObject=void 0;const dn=yn(bn);function vn(n){return null!==n&&"object"==typeof n}function pn(n){return(0,dn.default)(n)}R.isObject=vn,R.isntObject=function(n){return!vn(n)},R.isPlainObject=pn,R.isntPlainObject=function(n){return!pn(n)},R.isEmptyObject=function(n){return 0===Object.keys(n).length},R.isntEmptyObject=function(n){return 0!==Object.keys(n).length},x.isntJsonable=x.isJsonable=x.isntJson=x.isJson=void 0;const gn=u,jn=j,mn=h,On=T,hn=e,Nn=R;function Pn(n){return(0,gn.isNull)(n)||(0,jn.isBoolean)(n)||(0,mn.isString)(n)||(0,On.isNumber)(n)||(0,hn.isArray)(n)&&n.every(Pn)||(0,Nn.isPlainObject)(n)&&Object.values(n).every(Pn)}x.isJson=Pn,x.isntJson=function(n){return!Pn(n)},x.isJsonable=function(n){try{return JSON.stringify(n),!0}catch(n){return!1}},x.isntJsonable=function n(t){return!n()};var wn={};wn.isPromiseLike=wn.isntPromiseLike=wn.isntPromise=wn.isPromise=void 0;const An=R,Fn=a;function In(n){return n instanceof Promise}function Sn(n){return(0,An.isObject)(n)&&(0,Fn.isFunction)(n.then)}wn.isPromise=In,wn.isntPromise=function(n){return!In(n)},wn.isntPromiseLike=function(n){return!Sn(n)},wn.isPromiseLike=Sn;var En={}; | ||
***************************************************************************** */ | ||
function Dn(n,t,i,e){return new(i||(i=Promise))((function(r,o){function u(n){try{c(e.next(n))}catch(n){o(n)}}function s(n){try{c(e.throw(n))}catch(n){o(n)}}function c(n){var t;n.done?r(n.value):(t=n.value,t instanceof i?t:new i((function(n){n(t)}))).then(u,s)}c((e=e.apply(n,t||[])).next())}))}En.isAbsoluteURL=void 0,En.isAbsoluteURL=function(n){try{return new URL(n),!0}catch(n){return!1}},function(n){var i=t&&t.__createBinding||(Object.create?function(n,t,i,e){void 0===e&&(e=i);var r=Object.getOwnPropertyDescriptor(t,i);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[i]}}),Object.defineProperty(n,e,r)}:function(n,t,i,e){void 0===e&&(e=i),n[e]=t[i]}),r=t&&t.__exportStar||function(n,t){for(var e in n)"default"===e||Object.prototype.hasOwnProperty.call(t,e)||i(t,n,e)};r(e,n),r(o,n),r(p,n),r(j,n),r(O,n),r(A,n),r(I,n),r(S,n),r(D,n),r(a,n),r(B,n),r(x,n),r(u,n),r(T,n),r(R,n),r(wn,n),r(h,n),r(c,n),r(En,n)}(i),n.log=function(...n){return console.log(...n),n[n.length-1]},n.time=function(n,t){const e=Date.now(),r=t();if(i.isPromiseLike(r))return r.then((()=>{const t=Date.now();return console.log(n,t-e+"ms"),r}));{const t=Date.now();return console.log(n,t-e+"ms"),r}},n.timeAsyncFunction=function(n,t){return function(...i){return Dn(this,void 0,void 0,(function*(){const e=Date.now(),r=yield t(...i),o=Date.now();return console.log(n,e-o+"ms"),r}))}},n.timeFunction=function(n,t){return function(...i){const e=Date.now(),r=t(...i),o=Date.now();return console.log(n,e-o+"ms"),r}},Object.defineProperty(n,"__esModule",{value:!0})})); | ||
function Dn(n,t,i,e){return new(i||(i=Promise))((function(r,o){function u(n){try{c(e.next(n))}catch(n){o(n)}}function s(n){try{c(e.throw(n))}catch(n){o(n)}}function c(n){var t;n.done?r(n.value):(t=n.value,t instanceof i?t:new i((function(n){n(t)}))).then(u,s)}c((e=e.apply(n,t||[])).next())}))}En.isAbsoluteURL=void 0,En.isAbsoluteURL=function(n){try{return new URL(n),!0}catch(n){return!1}},function(n){var i=t&&t.__createBinding||(Object.create?function(n,t,i,e){void 0===e&&(e=i);var r=Object.getOwnPropertyDescriptor(t,i);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[i]}}),Object.defineProperty(n,e,r)}:function(n,t,i,e){void 0===e&&(e=i),n[e]=t[i]}),r=t&&t.__exportStar||function(n,t){for(var e in n)"default"===e||Object.prototype.hasOwnProperty.call(t,e)||i(t,n,e)};r(e,n),r(o,n),r(p,n),r(j,n),r(O,n),r(A,n),r(I,n),r(S,n),r(D,n),r(a,n),r(B,n),r(x,n),r(u,n),r(T,n),r(R,n),r(wn,n),r(h,n),r(c,n),r(En,n)}(i),n.log=function(...n){return console.log(...n),n[n.length-1]},n.time=function(n,t){const e=Date.now(),r=t();if(i.isPromiseLike(r))return r.then((()=>{const t=Date.now();return console.log(n,t-e+"ms"),r}));{const t=Date.now();return console.log(n,t-e+"ms"),r}},n.timeAsyncFunction=function(n,t){return function(...i){return Dn(this,void 0,void 0,(function*(){const e=Date.now(),r=yield t(...i),o=Date.now();return console.log(n,o-e+"ms"),r}))}},n.timeFunction=function(n,t){return function(...i){const e=Date.now(),r=t(...i),o=Date.now();return console.log(n,o-e+"ms"),r}},Object.defineProperty(n,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=index.umd.min.js.map |
@@ -637,3 +637,3 @@ (function (global, factory) { | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -648,3 +648,3 @@ }; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -651,0 +651,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
!function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((n="undefined"!=typeof globalThis?globalThis:n||self).Log={})}(this,(function(n){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},i={},e={};function r(n){return Array.isArray(n)}e.isntEmptyArray=e.isEmptyArray=e.isntArray=e.isArray=void 0,e.isArray=r,e.isntArray=function(n){return!r(n)},e.isEmptyArray=function(n){return 0===n.length},e.isntEmptyArray=function(n){return 0!==n.length};var o={},s={};function u(n){return null===n}s.isntNull=s.isNull=void 0,s.isNull=u,s.isntNull=function(n){return!u(n)};var c={};function f(n){return void 0===n}c.isntUndefined=c.isUndefined=void 0,c.isUndefined=f,c.isntUndefined=function(n){return!f(n)};var a={};function l(n){return"function"==typeof n}a.isntFunction=a.isFunction=void 0,a.isFunction=l,a.isntFunction=function(n){return!l(n)},o.isntAsyncIterable=o.isAsyncIterable=void 0;const b=s,y=c,d=a;function v(n){return(0,b.isntNull)(n)&&(0,y.isntUndefined)(n)&&(0,d.isFunction)(n[Symbol.asyncIterator])}o.isAsyncIterable=v,o.isntAsyncIterable=function(n){return!v(n)};var p={};function g(n){return"bigint"==typeof n}p.isntBigInt=p.isBigInt=void 0,p.isBigInt=g,p.isntBigInt=function(n){return!g(n)};var j={};function m(n){return"boolean"==typeof n}j.isntBoolean=j.isBoolean=void 0,j.isBoolean=m,j.isntBoolean=function(n){return!m(n)};var O={},N={};function h(n){return"string"==typeof n}N.isntString=N.isString=void 0,N.isString=h,N.isntString=function(n){return!h(n)},O.isntChar=O.isChar=void 0;const P=N;function w(n){return(0,P.isString)(n)&&1===n.length}O.isChar=w,O.isntChar=function(n){return!w(n)};var A={};function F(n){return n instanceof Date}A.isntDate=A.isDate=void 0,A.isDate=F,A.isntDate=function(n){return!F(n)};var I={};I.inEnum=void 0,I.inEnum=function(n,t){return Object.values(t).includes(n)};var S={};function E(n){return n instanceof Error}S.isntError=S.isError=void 0,S.isError=E,S.isntError=function(n){return!E(n)};var D={};function _(n){return!n}D.isntFalsy=D.isFalsy=void 0,D.isFalsy=_,D.isntFalsy=function(n){return!_(n)};var B={};B.isntIterable=B.isIterable=void 0;const U=s,J=c,L=a;function k(n){return(0,U.isntNull)(n)&&(0,J.isntUndefined)(n)&&(0,L.isFunction)(n[Symbol.iterator])}B.isIterable=k,B.isntIterable=function(n){return!k(n)};var T={},x={};function C(n){return"number"==typeof n}function M(n){return Number.isNaN(n)}x.isntNaN=x.isNaN=x.isNegativeInfinity=x.isPositiveInfinity=x.isFinite=x.isntNumber=x.isNumber=void 0,x.isNumber=C,x.isntNumber=function(n){return!C(n)},x.isFinite=function(n){return Number.isFinite(n)},x.isPositiveInfinity=function(n){return n===1/0},x.isNegativeInfinity=function(n){return n===-1/0},x.isNaN=M,x.isntNaN=function(n){return!M(n)};var R={},q="object"==typeof t&&t&&t.Object===Object&&t,z="object"==typeof self&&self&&self.Object===Object&&self,G=(q||z||Function("return this")()).Symbol,H=G,K=Object.prototype,Q=K.hasOwnProperty,V=K.toString,W=H?H.toStringTag:void 0;var X=function(n){var t=Q.call(n,W),i=n[W];try{n[W]=void 0;var e=!0}catch(n){}var r=V.call(n);return e&&(t?n[W]=i:delete n[W]),r},Y=Object.prototype.toString;var Z=X,$=function(n){return Y.call(n)},nn=G?G.toStringTag:void 0;var tn=function(n){return null==n?void 0===n?"[object Undefined]":"[object Null]":nn&&nn in Object(n)?Z(n):$(n)};var en=function(n,t){return function(i){return n(t(i))}}(Object.getPrototypeOf,Object);var rn=tn,on=en,sn=function(n){return null!=n&&"object"==typeof n},un=Function.prototype,cn=Object.prototype,fn=un.toString,an=cn.hasOwnProperty,ln=fn.call(Object);var bn=function(n){if(!sn(n)||"[object Object]"!=rn(n))return!1;var t=on(n);if(null===t)return!0;var i=an.call(t,"constructor")&&t.constructor;return"function"==typeof i&&i instanceof i&&fn.call(i)==ln},yn=t&&t.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};R.isntEmptyObject=R.isEmptyObject=R.isntPlainObject=R.isPlainObject=R.isntObject=R.isObject=void 0;const dn=yn(bn);function vn(n){return null!==n&&"object"==typeof n}function pn(n){return(0,dn.default)(n)}R.isObject=vn,R.isntObject=function(n){return!vn(n)},R.isPlainObject=pn,R.isntPlainObject=function(n){return!pn(n)},R.isEmptyObject=function(n){return 0===Object.keys(n).length},R.isntEmptyObject=function(n){return 0!==Object.keys(n).length},T.isntJsonable=T.isJsonable=T.isntJson=T.isJson=void 0;const gn=s,jn=j,mn=N,On=x,Nn=e,hn=R;function Pn(n){return(0,gn.isNull)(n)||(0,jn.isBoolean)(n)||(0,mn.isString)(n)||(0,On.isNumber)(n)||(0,Nn.isArray)(n)&&n.every(Pn)||(0,hn.isPlainObject)(n)&&Object.values(n).every(Pn)}T.isJson=Pn,T.isntJson=function(n){return!Pn(n)},T.isJsonable=function(n){try{return JSON.stringify(n),!0}catch(n){return!1}},T.isntJsonable=function n(t){return!n()};var wn={};wn.isPromiseLike=wn.isntPromiseLike=wn.isntPromise=wn.isPromise=void 0;const An=R,Fn=a;function In(n){return n instanceof Promise}function Sn(n){return(0,An.isObject)(n)&&(0,Fn.isFunction)(n.then)}wn.isPromise=In,wn.isntPromise=function(n){return!In(n)},wn.isntPromiseLike=function(n){return!Sn(n)},wn.isPromiseLike=Sn;var En={};En.isAbsoluteURL=void 0,En.isAbsoluteURL=function(n){try{return new URL(n),!0}catch(n){return!1}},function(n){var i=t&&t.__createBinding||(Object.create?function(n,t,i,e){void 0===e&&(e=i);var r=Object.getOwnPropertyDescriptor(t,i);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[i]}}),Object.defineProperty(n,e,r)}:function(n,t,i,e){void 0===e&&(e=i),n[e]=t[i]}),r=t&&t.__exportStar||function(n,t){for(var e in n)"default"===e||Object.prototype.hasOwnProperty.call(t,e)||i(t,n,e)};r(e,n),r(o,n),r(p,n),r(j,n),r(O,n),r(A,n),r(I,n),r(S,n),r(D,n),r(a,n),r(B,n),r(T,n),r(s,n),r(x,n),r(R,n),r(wn,n),r(N,n),r(c,n),r(En,n)}(i),n.log=function(...n){return console.log(...n),n[n.length-1]},n.time=function(n,t){const e=Date.now(),r=t();if(i.isPromiseLike(r))return r.then((()=>{const t=Date.now();return console.log(n,t-e+"ms"),r}));{const t=Date.now();return console.log(n,t-e+"ms"),r}},n.timeAsyncFunction=function(n,t){return async function(...i){const e=Date.now(),r=await t(...i),o=Date.now();return console.log(n,e-o+"ms"),r}},n.timeFunction=function(n,t){return function(...i){const e=Date.now(),r=t(...i),o=Date.now();return console.log(n,e-o+"ms"),r}},Object.defineProperty(n,"__esModule",{value:!0})})); | ||
!function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((n="undefined"!=typeof globalThis?globalThis:n||self).Log={})}(this,(function(n){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},i={},e={};function r(n){return Array.isArray(n)}e.isntEmptyArray=e.isEmptyArray=e.isntArray=e.isArray=void 0,e.isArray=r,e.isntArray=function(n){return!r(n)},e.isEmptyArray=function(n){return 0===n.length},e.isntEmptyArray=function(n){return 0!==n.length};var o={},s={};function u(n){return null===n}s.isntNull=s.isNull=void 0,s.isNull=u,s.isntNull=function(n){return!u(n)};var c={};function f(n){return void 0===n}c.isntUndefined=c.isUndefined=void 0,c.isUndefined=f,c.isntUndefined=function(n){return!f(n)};var a={};function l(n){return"function"==typeof n}a.isntFunction=a.isFunction=void 0,a.isFunction=l,a.isntFunction=function(n){return!l(n)},o.isntAsyncIterable=o.isAsyncIterable=void 0;const b=s,y=c,d=a;function v(n){return(0,b.isntNull)(n)&&(0,y.isntUndefined)(n)&&(0,d.isFunction)(n[Symbol.asyncIterator])}o.isAsyncIterable=v,o.isntAsyncIterable=function(n){return!v(n)};var p={};function g(n){return"bigint"==typeof n}p.isntBigInt=p.isBigInt=void 0,p.isBigInt=g,p.isntBigInt=function(n){return!g(n)};var j={};function m(n){return"boolean"==typeof n}j.isntBoolean=j.isBoolean=void 0,j.isBoolean=m,j.isntBoolean=function(n){return!m(n)};var O={},N={};function h(n){return"string"==typeof n}N.isntString=N.isString=void 0,N.isString=h,N.isntString=function(n){return!h(n)},O.isntChar=O.isChar=void 0;const P=N;function w(n){return(0,P.isString)(n)&&1===n.length}O.isChar=w,O.isntChar=function(n){return!w(n)};var A={};function F(n){return n instanceof Date}A.isntDate=A.isDate=void 0,A.isDate=F,A.isntDate=function(n){return!F(n)};var I={};I.inEnum=void 0,I.inEnum=function(n,t){return Object.values(t).includes(n)};var S={};function E(n){return n instanceof Error}S.isntError=S.isError=void 0,S.isError=E,S.isntError=function(n){return!E(n)};var D={};function _(n){return!n}D.isntFalsy=D.isFalsy=void 0,D.isFalsy=_,D.isntFalsy=function(n){return!_(n)};var B={};B.isntIterable=B.isIterable=void 0;const U=s,J=c,L=a;function k(n){return(0,U.isntNull)(n)&&(0,J.isntUndefined)(n)&&(0,L.isFunction)(n[Symbol.iterator])}B.isIterable=k,B.isntIterable=function(n){return!k(n)};var T={},x={};function C(n){return"number"==typeof n}function M(n){return Number.isNaN(n)}x.isntNaN=x.isNaN=x.isNegativeInfinity=x.isPositiveInfinity=x.isFinite=x.isntNumber=x.isNumber=void 0,x.isNumber=C,x.isntNumber=function(n){return!C(n)},x.isFinite=function(n){return Number.isFinite(n)},x.isPositiveInfinity=function(n){return n===1/0},x.isNegativeInfinity=function(n){return n===-1/0},x.isNaN=M,x.isntNaN=function(n){return!M(n)};var R={},q="object"==typeof t&&t&&t.Object===Object&&t,z="object"==typeof self&&self&&self.Object===Object&&self,G=(q||z||Function("return this")()).Symbol,H=G,K=Object.prototype,Q=K.hasOwnProperty,V=K.toString,W=H?H.toStringTag:void 0;var X=function(n){var t=Q.call(n,W),i=n[W];try{n[W]=void 0;var e=!0}catch(n){}var r=V.call(n);return e&&(t?n[W]=i:delete n[W]),r},Y=Object.prototype.toString;var Z=X,$=function(n){return Y.call(n)},nn=G?G.toStringTag:void 0;var tn=function(n){return null==n?void 0===n?"[object Undefined]":"[object Null]":nn&&nn in Object(n)?Z(n):$(n)};var en=function(n,t){return function(i){return n(t(i))}}(Object.getPrototypeOf,Object);var rn=tn,on=en,sn=function(n){return null!=n&&"object"==typeof n},un=Function.prototype,cn=Object.prototype,fn=un.toString,an=cn.hasOwnProperty,ln=fn.call(Object);var bn=function(n){if(!sn(n)||"[object Object]"!=rn(n))return!1;var t=on(n);if(null===t)return!0;var i=an.call(t,"constructor")&&t.constructor;return"function"==typeof i&&i instanceof i&&fn.call(i)==ln},yn=t&&t.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};R.isntEmptyObject=R.isEmptyObject=R.isntPlainObject=R.isPlainObject=R.isntObject=R.isObject=void 0;const dn=yn(bn);function vn(n){return null!==n&&"object"==typeof n}function pn(n){return(0,dn.default)(n)}R.isObject=vn,R.isntObject=function(n){return!vn(n)},R.isPlainObject=pn,R.isntPlainObject=function(n){return!pn(n)},R.isEmptyObject=function(n){return 0===Object.keys(n).length},R.isntEmptyObject=function(n){return 0!==Object.keys(n).length},T.isntJsonable=T.isJsonable=T.isntJson=T.isJson=void 0;const gn=s,jn=j,mn=N,On=x,Nn=e,hn=R;function Pn(n){return(0,gn.isNull)(n)||(0,jn.isBoolean)(n)||(0,mn.isString)(n)||(0,On.isNumber)(n)||(0,Nn.isArray)(n)&&n.every(Pn)||(0,hn.isPlainObject)(n)&&Object.values(n).every(Pn)}T.isJson=Pn,T.isntJson=function(n){return!Pn(n)},T.isJsonable=function(n){try{return JSON.stringify(n),!0}catch(n){return!1}},T.isntJsonable=function n(t){return!n()};var wn={};wn.isPromiseLike=wn.isntPromiseLike=wn.isntPromise=wn.isPromise=void 0;const An=R,Fn=a;function In(n){return n instanceof Promise}function Sn(n){return(0,An.isObject)(n)&&(0,Fn.isFunction)(n.then)}wn.isPromise=In,wn.isntPromise=function(n){return!In(n)},wn.isntPromiseLike=function(n){return!Sn(n)},wn.isPromiseLike=Sn;var En={};En.isAbsoluteURL=void 0,En.isAbsoluteURL=function(n){try{return new URL(n),!0}catch(n){return!1}},function(n){var i=t&&t.__createBinding||(Object.create?function(n,t,i,e){void 0===e&&(e=i);var r=Object.getOwnPropertyDescriptor(t,i);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[i]}}),Object.defineProperty(n,e,r)}:function(n,t,i,e){void 0===e&&(e=i),n[e]=t[i]}),r=t&&t.__exportStar||function(n,t){for(var e in n)"default"===e||Object.prototype.hasOwnProperty.call(t,e)||i(t,n,e)};r(e,n),r(o,n),r(p,n),r(j,n),r(O,n),r(A,n),r(I,n),r(S,n),r(D,n),r(a,n),r(B,n),r(T,n),r(s,n),r(x,n),r(R,n),r(wn,n),r(N,n),r(c,n),r(En,n)}(i),n.log=function(...n){return console.log(...n),n[n.length-1]},n.time=function(n,t){const e=Date.now(),r=t();if(i.isPromiseLike(r))return r.then((()=>{const t=Date.now();return console.log(n,t-e+"ms"),r}));{const t=Date.now();return console.log(n,t-e+"ms"),r}},n.timeAsyncFunction=function(n,t){return async function(...i){const e=Date.now(),r=await t(...i),o=Date.now();return console.log(n,o-e+"ms"),r}},n.timeFunction=function(n,t){return function(...i){const e=Date.now(),r=t(...i),o=Date.now();return console.log(n,o-e+"ms"),r}},Object.defineProperty(n,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=index.umd.min.js.map |
@@ -19,3 +19,3 @@ "use strict"; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -22,0 +22,0 @@ }); |
@@ -9,3 +9,3 @@ "use strict"; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -12,0 +12,0 @@ }; |
@@ -9,3 +9,3 @@ "use strict"; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -12,0 +12,0 @@ }; |
@@ -9,3 +9,3 @@ "use strict"; | ||
const endTime = Date.now(); | ||
console.log(message, `${startTime - endTime}ms`); | ||
console.log(message, `${endTime - startTime}ms`); | ||
return result; | ||
@@ -12,0 +12,0 @@ }; |
{ | ||
"name": "@blackglory/log", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "keywords": [], |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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