ast-contains-only-empty-space
Advanced tools
Comparing version 1.3.3 to 1.4.0
@@ -8,2 +8,6 @@ # Change Log | ||
## [1.4.0] - 2018-10-13 | ||
- ✨ Updated all dependencies and restored coverage tracking both via terminal when testing and through coveralls.io | ||
## [1.3.0] - 2018-06-13 | ||
@@ -38,4 +42,5 @@ | ||
[1.4.0]: https://bitbucket.org/codsen/ast-contains-only-empty-space/branches/compare/v1.4.0%0Dv1.3.3#diff | ||
[1.3.0]: https://bitbucket.org/codsen/ast-contains-only-empty-space/branches/compare/v1.3.0%0Dv1.2.2#diff | ||
[1.2.0]: https://bitbucket.org/codsen/ast-contains-only-empty-space/branches/compare/v1.2.0%0Dv1.1.1#diff | ||
[1.1.0]: https://bitbucket.org/codsen/ast-contains-only-empty-space/branches/compare/v1.1.0%0Dv1.0.2#diff |
@@ -9,4 +9,2 @@ 'use strict'; | ||
/* eslint no-param-reassign:0 */ | ||
function containsOnlyEmptySpace(input) { | ||
@@ -18,3 +16,2 @@ function isStr(something) { | ||
var found = true; | ||
if (!isArr(input) && !isObj(input) && !isStr(input)) { | ||
@@ -32,3 +29,2 @@ return false; | ||
}); | ||
return found; | ||
@@ -35,0 +31,0 @@ } |
@@ -5,4 +5,2 @@ import trim from 'lodash.trim'; | ||
/* eslint no-param-reassign:0 */ | ||
function containsOnlyEmptySpace(input) { | ||
@@ -14,3 +12,2 @@ function isStr(something) { | ||
let found = true; | ||
if (!isArr(input) && !isObj(input) && !isStr(input)) { | ||
@@ -28,3 +25,2 @@ return false; | ||
}); | ||
return found; | ||
@@ -31,0 +27,0 @@ } |
@@ -1,1 +0,1 @@ | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.astContainsOnlyEmptySpace=e()}(this,function(){"use strict";var wt="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};var o="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},i=1/0,u="[object Symbol]",f=/^\s+|\s+$/g,t="\\ud800-\\udfff",e="\\u0300-\\u036f\\ufe20-\\ufe23",n="\\u20d0-\\u20f0",r="\\ufe0e\\ufe0f",c="["+t+"]",a="["+e+n+"]",l="\\ud83c[\\udffb-\\udfff]",s="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",y="[\\ud800-\\udbff][\\udc00-\\udfff]",d="\\u200d",v="(?:"+a+"|"+l+")"+"?",h="["+r+"]?",_=h+v+("(?:"+d+"(?:"+[s,p,y].join("|")+")"+h+v+")*"),b="(?:"+[s+a+"?",a,p,y,c].join("|")+")",g=RegExp(l+"(?="+l+")|"+b+_,"g"),j=RegExp("["+d+t+e+n+r+"]"),m="object"==o(wt)&&wt&&wt.Object===Object&&wt,O="object"==("undefined"==typeof self?"undefined":o(self))&&self&&self.Object===Object&&self,S=m||O||Function("return this")();function w(t,e,n){if(e!=e)return function(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i<o;)if(e(t[i],i,t))return i;return-1}(t,x,n);for(var r=n-1,o=t.length;++r<o;)if(t[r]===e)return r;return-1}function x(t){return t!=t}function A(t){return e=t,j.test(e)?t.match(g)||[]:t.split("");var e}var P=Object.prototype.toString,$=S.Symbol,k=$?$.prototype:void 0,E=k?k.toString:void 0;function F(t){if("string"==typeof t)return t;if("symbol"==(void 0===(e=t)?"undefined":o(e))||(n=e)&&"object"==(void 0===n?"undefined":o(n))&&P.call(e)==u)return E?E.call(t):"";var e,n,r=t+"";return"0"==r&&1/t==-i?"-0":r}function N(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&r<=n?t:function(t,e,n){var r=-1,o=t.length;e<0&&(e=o<-e?0:o+e),(n=o<n?o:n)<0&&(n+=o),o=n<e?0:n-e>>>0,e>>>=0;for(var i=Array(o);++r<o;)i[r]=t[r+e];return i}(t,e,n)}var M=function(t,e,n){var r;if((t=null==(r=t)?"":F(r))&&(n||void 0===e))return t.replace(f,"");if(!t||!(e=F(e)))return t;var o=A(t),i=A(e);return N(o,function(t,e){for(var n=-1,r=t.length;++n<r&&-1<w(e,t[n],0););return n}(o,i),function(t,e){for(var n=t.length;n--&&-1<w(e,t[n],0););return n}(o,i)+1).join("")},R="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};var B,T,C=Function.prototype,D=Object.prototype,I=C.toString,V=D.hasOwnProperty,W=I.call(Object),G=D.toString,K=(B=Object.getPrototypeOf,T=Object,function(t){return B(T(t))});var U,q=function(t){if(!(e=t)||"object"!=(void 0===e?"undefined":R(e))||"[object Object]"!=G.call(t)||function(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}(t))return!1;var e,n=K(t);if(null===n)return!0;var r=V.call(n,"constructor")&&n.constructor;return"function"==typeof r&&r instanceof r&&I.call(r)==W},xt="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},z=(function(t,e){var r="__lodash_hash_undefined__",n=9007199254740991,O="[object Arguments]",S="[object Function]",w="[object GeneratorFunction]",o="[object Map]",x="[object Object]",i="[object Promise]",u="[object Set]",f="[object WeakMap]",c="[object DataView]",a=/^\[object .+?Constructor\]$/,l=/^(?:0|[1-9]\d*)$/,s="object"==xt(wt)&&wt&&wt.Object===Object&&wt,p="object"==("undefined"==typeof self?"undefined":xt(self))&&self&&self.Object===Object&&self,y=s||p||Function("return this")(),d=e&&!e.nodeType&&e,v=d&&t&&!t.nodeType&&t,h=v&&v.exports===d;function A(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}function _(e,n){return function(t){return e(n(t))}}var b,g=Array.prototype,j=Function.prototype,m=Object.prototype,P=y["__core-js_shared__"],$=(b=/[^.]+$/.exec(P&&P.keys&&P.keys.IE_PROTO||""))?"Symbol(src)_1."+b:"",k=j.toString,E=m.hasOwnProperty,F=m.toString,N=RegExp("^"+k.call(E).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),M=h?y.Buffer:void 0,R=y.Symbol,B=(y.Uint8Array,_(Object.getPrototypeOf,Object)),T=Object.create,C=m.propertyIsEnumerable,D=g.splice,I=Object.getOwnPropertySymbols,V=M?M.isBuffer:void 0,W=_(Object.keys,Object),G=st(y,"DataView"),K=st(y,"Map"),U=st(y,"Promise"),q=st(y,"Set"),z=st(y,"WeakMap"),H=st(Object,"create"),J=ht(G),L=ht(K),Q=ht(U),X=ht(q),Y=ht(z),Z=R?R.prototype:void 0;Z&&Z.valueOf;function tt(t){var e=-1,n=t?t.length:0;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function et(t){var e=-1,n=t?t.length:0;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function nt(t){var e=-1,n=t?t.length:0;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function rt(t){this.__data__=new et(t)}function ot(t,e){var n,r,o,i=bt(t)||(o=r=n=t)&&"object"==(void 0===o?"undefined":xt(o))&>(r)&&E.call(n,"callee")&&(!C.call(n,"callee")||F.call(n)==O)?function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}(t.length,String):[],u=i.length,f=!!u;for(var c in t)!e&&!E.call(t,c)||f&&("length"==c||dt(c,u))||i.push(c);return i}function it(t,e,n){var r=t[e];E.call(t,e)&&_t(r,n)&&(void 0!==n||e in t)||(t[e]=n)}function ut(t,e){for(var n=t.length;n--;)if(_t(t[n][0],e))return n;return-1}function ft(n,r,o,i,t,e,u){var f;if(i&&(f=e?i(n,t,e,u):i(n)),void 0!==f)return f;if(!Ot(n))return n;var c,a,l,s,p,y,d=bt(n);if(d){if(f=function(t){var e=t.length,n=t.constructor(e);e&&"string"==typeof t[0]&&E.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(n),!r)return function(t,e){var n=-1,r=t.length;e||(e=Array(r));for(;++n<r;)e[n]=t[n];return e}(n,f)}else{var v=yt(n),h=v==S||v==w;if(jt(n))return function(t,e){if(e)return t.slice();var n=new t.constructor(t.length);return t.copy(n),n}(n,r);if(v!=x&&v!=O&&(!h||e))return e?n:{};if(A(n))return e?n:{};if(f="function"!=typeof(p=h?{}:n).constructor||vt(p)?{}:Ot(y=B(p))?T(y):{},!r)return s=c=n,a=(l=f)&&at(s,St(s),l),at(c,pt(c),a)}u||(u=new rt);var _,b,g,j=u.get(n);if(j)return j;if(u.set(n,f),!d)var m=o?(b=pt,g=St(_=n),bt(_)?g:function(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}(g,b(_))):St(n);return function(t,e){for(var n=-1,r=t?t.length:0;++n<r&&!1!==e(t[n],n,t););}(m||n,function(t,e){m&&(t=n[e=t]),it(f,e,ft(t,r,o,i,e,n,u))}),f}function ct(t){return!(!Ot(t)||(e=t,$&&$ in e))&&(mt(t)||A(t)?N:a).test(ht(t));var e}function at(t,e,n,r){n||(n={});for(var o=-1,i=e.length;++o<i;){var u=e[o],f=r?r(n[u],t[u],u,n,t):void 0;it(n,u,void 0===f?t[u]:f)}return n}function lt(t,e){var n,r,o=t.__data__;return("string"==(r=void 0===(n=e)?"undefined":xt(n))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof e?"string":"hash"]:o.map}function st(t,e){var n,r,o=(r=e,null==(n=t)?void 0:n[r]);return ct(o)?o:void 0}tt.prototype.clear=function(){this.__data__=H?H(null):{}},tt.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},tt.prototype.get=function(t){var e=this.__data__;if(H){var n=e[t];return n===r?void 0:n}return E.call(e,t)?e[t]:void 0},tt.prototype.has=function(t){var e=this.__data__;return H?void 0!==e[t]:E.call(e,t)},tt.prototype.set=function(t,e){return this.__data__[t]=H&&void 0===e?r:e,this},et.prototype.clear=function(){this.__data__=[]},et.prototype.delete=function(t){var e=this.__data__,n=ut(e,t);return!(n<0||(n==e.length-1?e.pop():D.call(e,n,1),0))},et.prototype.get=function(t){var e=this.__data__,n=ut(e,t);return n<0?void 0:e[n][1]},et.prototype.has=function(t){return-1<ut(this.__data__,t)},et.prototype.set=function(t,e){var n=this.__data__,r=ut(n,t);return r<0?n.push([t,e]):n[r][1]=e,this},nt.prototype.clear=function(){this.__data__={hash:new tt,map:new(K||et),string:new tt}},nt.prototype.delete=function(t){return lt(this,t).delete(t)},nt.prototype.get=function(t){return lt(this,t).get(t)},nt.prototype.has=function(t){return lt(this,t).has(t)},nt.prototype.set=function(t,e){return lt(this,t).set(t,e),this},rt.prototype.clear=function(){this.__data__=new et},rt.prototype.delete=function(t){return this.__data__.delete(t)},rt.prototype.get=function(t){return this.__data__.get(t)},rt.prototype.has=function(t){return this.__data__.has(t)},rt.prototype.set=function(t,e){var n=this.__data__;if(n instanceof et){var r=n.__data__;if(!K||r.length<199)return r.push([t,e]),this;n=this.__data__=new nt(r)}return n.set(t,e),this};var pt=I?_(I,Object):function(){return[]},yt=function(t){return F.call(t)};function dt(t,e){return!!(e=null==e?n:e)&&("number"==typeof t||l.test(t))&&-1<t&&t%1==0&&t<e}function vt(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||m)}function ht(t){if(null!=t){try{return k.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function _t(t,e){return t===e||t!=t&&e!=e}(G&&yt(new G(new ArrayBuffer(1)))!=c||K&&yt(new K)!=o||U&&yt(U.resolve())!=i||q&&yt(new q)!=u||z&&yt(new z)!=f)&&(yt=function(t){var e=F.call(t),n=e==x?t.constructor:void 0,r=n?ht(n):void 0;if(r)switch(r){case J:return c;case L:return o;case Q:return i;case X:return u;case Y:return f}return e});var bt=Array.isArray;function gt(t){return null!=t&&("number"==typeof(e=t.length)&&-1<e&&e%1==0&&e<=n)&&!mt(t);var e}var jt=V||function(){return!1};function mt(t){var e=Ot(t)?F.call(t):"";return e==S||e==w}function Ot(t){var e=void 0===t?"undefined":xt(t);return!!t&&("object"==e||"function"==e)}function St(t){return gt(t)?ot(t):function(t){if(!vt(t))return W(t);var e=[];for(var n in Object(t))E.call(t,n)&&"constructor"!=n&&e.push(n);return e}(t)}t.exports=function(t){return ft(t,!0,!0)}}(U={exports:{}},U.exports),U.exports),H=Array.isArray;function J(t){return"string"==typeof t&&0<t.length&&"."===t[0]?t.slice(1):t}return function(t){function r(t){return"string"==typeof t}var e=Array.isArray,o=!0;return!!(e(t)||q(t)||r(t))&&(r(t)?0===M(t).length:(t=function t(e,n,r){var o=z(e),i=void 0,u=void 0,f=void 0,c=void 0,a=void 0;if((r=Object.assign({depth:-1,path:""},r)).depth+=1,H(o))for(i=0,u=o.length;i<u;i++){var l=r.path+"."+i;void 0!==o[i]?(r.parent=z(o),f=t(n(o[i],void 0,Object.assign({},r,{path:J(l)})),n,Object.assign({},r,{path:J(l)})),Number.isNaN(f)&&i<o.length?(o.splice(i,1),i-=1):o[i]=f):o.splice(i,1)}else if(q(o))for(i=0,u=(c=Object.keys(o)).length;i<u;i++){a=c[i];var s=r.path+"."+a;0===r.depth&&null!=a&&(r.topmostKey=a),r.parent=z(o),f=t(n(a,o[a],Object.assign({},r,{path:J(s)})),n,Object.assign({},r,{path:J(s)})),Number.isNaN(f)?delete o[a]:o[a]=f}return o}(t,function(t,e){var n=void 0!==e?e:t;return r(n)&&""!==M(n)&&(o=!1),n},{}),o))}}); | ||
!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?module.exports=r():"function"==typeof define&&define.amd?define(r):t.astContainsOnlyEmptySpace=r()}(this,function(){"use strict";var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};var r=1/0,e="[object Symbol]",n=/^\s+|\s+$/g,o="[\\ud800-\\udfff]",u="[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]",c="\\ud83c[\\udffb-\\udfff]",i="[^\\ud800-\\udfff]",a="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",s="(?:"+u+"|"+c+")"+"?",l="[\\ufe0e\\ufe0f]?"+s+("(?:\\u200d(?:"+[i,a,f].join("|")+")[\\ufe0e\\ufe0f]?"+s+")*"),p="(?:"+[i+u+"?",u,a,f,o].join("|")+")",y=RegExp(c+"(?="+c+")|"+p+l,"g"),h=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0\\ufe0e\\ufe0f]"),d="object"==typeof t&&t&&t.Object===Object&&t,v="object"==typeof self&&self&&self.Object===Object&&self,b=d||v||Function("return this")();function _(t,r,e){if(r!=r)return function(t,r,e,n){for(var o=t.length,u=e+(n?1:-1);n?u--:++u<o;)if(r(t[u],u,t))return u;return-1}(t,j,e);for(var n=e-1,o=t.length;++n<o;)if(t[n]===r)return n;return-1}function j(t){return t!=t}function g(t){return function(t){return h.test(t)}(t)?function(t){return t.match(y)||[]}(t):function(t){return t.split("")}(t)}var O=Object.prototype.toString,w=b.Symbol,m=w?w.prototype:void 0,A=m?m.toString:void 0;function S(t){if("string"==typeof t)return t;if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&O.call(t)==e}(t))return A?A.call(t):"";var n=t+"";return"0"==n&&1/t==-r?"-0":n}function x(t,r,e){var n=t.length;return e=void 0===e?n:e,!r&&e>=n?t:function(t,r,e){var n=-1,o=t.length;r<0&&(r=-r>o?0:o+r),(e=e>o?o:e)<0&&(e+=o),o=r>e?0:e-r>>>0,r>>>=0;for(var u=Array(o);++n<o;)u[n]=t[n+r];return u}(t,r,e)}var $=function(t,r,e){var o;if((t=null==(o=t)?"":S(o))&&(e||void 0===r))return t.replace(n,"");if(!t||!(r=S(r)))return t;var u=g(t),c=g(r);return x(u,function(t,r){for(var e=-1,n=t.length;++e<n&&_(r,t[e],0)>-1;);return e}(u,c),function(t,r){for(var e=t.length;e--&&_(r,t[e],0)>-1;);return e}(u,c)+1).join("")},E="[object Object]";var P,k,F=Function.prototype,I=Object.prototype,N=F.toString,M=I.hasOwnProperty,B=N.call(Object),R=I.toString,U=(P=Object.getPrototypeOf,k=Object,function(t){return P(k(t))});var W,C=function(t){if(!function(t){return!!t&&"object"==typeof t}(t)||R.call(t)!=E||function(t){var r=!1;if(null!=t&&"function"!=typeof t.toString)try{r=!!(t+"")}catch(t){}return r}(t))return!1;var r=U(t);if(null===r)return!0;var e=M.call(r,"constructor")&&r.constructor;return"function"==typeof e&&e instanceof e&&N.call(e)==B},D=(function(r,e){var n=200,o="__lodash_hash_undefined__",u=9007199254740991,c="[object Arguments]",i="[object Boolean]",a="[object Date]",f="[object Function]",s="[object GeneratorFunction]",l="[object Map]",p="[object Number]",y="[object Object]",h="[object RegExp]",d="[object Set]",v="[object String]",b="[object Symbol]",_="[object ArrayBuffer]",j="[object DataView]",g="[object Float32Array]",O="[object Float64Array]",w="[object Int8Array]",m="[object Int16Array]",A="[object Int32Array]",S="[object Uint8Array]",x="[object Uint8ClampedArray]",$="[object Uint16Array]",E="[object Uint32Array]",P=/\w*$/,k=/^\[object .+?Constructor\]$/,F=/^(?:0|[1-9]\d*)$/,I={};I[c]=I["[object Array]"]=I[_]=I[j]=I[i]=I[a]=I[g]=I[O]=I[w]=I[m]=I[A]=I[l]=I[p]=I[y]=I[h]=I[d]=I[v]=I[b]=I[S]=I[x]=I[$]=I[E]=!0,I["[object Error]"]=I[f]=I["[object WeakMap]"]=!1;var N="object"==typeof t&&t&&t.Object===Object&&t,M="object"==typeof self&&self&&self.Object===Object&&self,B=N||M||Function("return this")(),R=e&&!e.nodeType&&e,U=R&&r&&!r.nodeType&&r,W=U&&U.exports===R;function C(t,r){return t.set(r[0],r[1]),t}function D(t,r){return t.add(r),t}function T(t,r,e,n){var o=-1,u=t?t.length:0;for(n&&u&&(e=t[++o]);++o<u;)e=r(e,t[o],o,t);return e}function z(t){var r=!1;if(null!=t&&"function"!=typeof t.toString)try{r=!!(t+"")}catch(t){}return r}function L(t){var r=-1,e=Array(t.size);return t.forEach(function(t,n){e[++r]=[n,t]}),e}function V(t,r){return function(e){return t(r(e))}}function G(t){var r=-1,e=Array(t.size);return t.forEach(function(t){e[++r]=t}),e}var K,q=Array.prototype,H=Function.prototype,J=Object.prototype,Q=B["__core-js_shared__"],X=(K=/[^.]+$/.exec(Q&&Q.keys&&Q.keys.IE_PROTO||""))?"Symbol(src)_1."+K:"",Y=H.toString,Z=J.hasOwnProperty,tt=J.toString,rt=RegExp("^"+Y.call(Z).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),et=W?B.Buffer:void 0,nt=B.Symbol,ot=B.Uint8Array,ut=V(Object.getPrototypeOf,Object),ct=Object.create,it=J.propertyIsEnumerable,at=q.splice,ft=Object.getOwnPropertySymbols,st=et?et.isBuffer:void 0,lt=V(Object.keys,Object),pt=Ut(B,"DataView"),yt=Ut(B,"Map"),ht=Ut(B,"Promise"),dt=Ut(B,"Set"),vt=Ut(B,"WeakMap"),bt=Ut(Object,"create"),_t=zt(pt),jt=zt(yt),gt=zt(ht),Ot=zt(dt),wt=zt(vt),mt=nt?nt.prototype:void 0,At=mt?mt.valueOf:void 0;function St(t){var r=-1,e=t?t.length:0;for(this.clear();++r<e;){var n=t[r];this.set(n[0],n[1])}}function xt(t){var r=-1,e=t?t.length:0;for(this.clear();++r<e;){var n=t[r];this.set(n[0],n[1])}}function $t(t){var r=-1,e=t?t.length:0;for(this.clear();++r<e;){var n=t[r];this.set(n[0],n[1])}}function Et(t){this.__data__=new xt(t)}function Pt(t,r){var e=Vt(t)||function(t){return function(t){return function(t){return!!t&&"object"==typeof t}(t)&&Gt(t)}(t)&&Z.call(t,"callee")&&(!it.call(t,"callee")||tt.call(t)==c)}(t)?function(t,r){for(var e=-1,n=Array(t);++e<t;)n[e]=r(e);return n}(t.length,String):[],n=e.length,o=!!n;for(var u in t)!r&&!Z.call(t,u)||o&&("length"==u||Dt(u,n))||e.push(u);return e}function kt(t,r,e){var n=t[r];Z.call(t,r)&&Lt(n,e)&&(void 0!==e||r in t)||(t[r]=e)}function Ft(t,r){for(var e=t.length;e--;)if(Lt(t[e][0],r))return e;return-1}function It(t,r,e,n,o,u,k){var F;if(n&&(F=u?n(t,o,u,k):n(t)),void 0!==F)return F;if(!Ht(t))return t;var N=Vt(t);if(N){if(F=function(t){var r=t.length,e=t.constructor(r);r&&"string"==typeof t[0]&&Z.call(t,"index")&&(e.index=t.index,e.input=t.input);return e}(t),!r)return function(t,r){var e=-1,n=t.length;r||(r=Array(n));for(;++e<n;)r[e]=t[e];return r}(t,F)}else{var M=Ct(t),B=M==f||M==s;if(Kt(t))return function(t,r){if(r)return t.slice();var e=new t.constructor(t.length);return t.copy(e),e}(t,r);if(M==y||M==c||B&&!u){if(z(t))return u?t:{};if(F=function(t){return"function"!=typeof t.constructor||Tt(t)?{}:(r=ut(t),Ht(r)?ct(r):{});var r}(B?{}:t),!r)return function(t,r){return Bt(t,Wt(t),r)}(t,function(t,r){return t&&Bt(r,Jt(r),t)}(F,t))}else{if(!I[M])return u?t:{};F=function(t,r,e,n){var o=t.constructor;switch(r){case _:return Mt(t);case i:case a:return new o(+t);case j:return function(t,r){var e=r?Mt(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.byteLength)}(t,n);case g:case O:case w:case m:case A:case S:case x:case $:case E:return function(t,r){var e=r?Mt(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}(t,n);case l:return function(t,r,e){return T(r?e(L(t),!0):L(t),C,new t.constructor)}(t,n,e);case p:case v:return new o(t);case h:return(f=new(c=t).constructor(c.source,P.exec(c))).lastIndex=c.lastIndex,f;case d:return function(t,r,e){return T(r?e(G(t),!0):G(t),D,new t.constructor)}(t,n,e);case b:return u=t,At?Object(At.call(u)):{}}var u;var c,f}(t,M,It,r)}}k||(k=new Et);var R=k.get(t);if(R)return R;if(k.set(t,F),!N)var U=e?function(t){return function(t,r,e){var n=r(t);return Vt(t)?n:function(t,r){for(var e=-1,n=r.length,o=t.length;++e<n;)t[o+e]=r[e];return t}(n,e(t))}(t,Jt,Wt)}(t):Jt(t);return function(t,r){for(var e=-1,n=t?t.length:0;++e<n&&!1!==r(t[e],e,t););}(U||t,function(o,u){U&&(o=t[u=o]),kt(F,u,It(o,r,e,n,u,t,k))}),F}function Nt(t){return!(!Ht(t)||(r=t,X&&X in r))&&(qt(t)||z(t)?rt:k).test(zt(t));var r}function Mt(t){var r=new t.constructor(t.byteLength);return new ot(r).set(new ot(t)),r}function Bt(t,r,e,n){e||(e={});for(var o=-1,u=r.length;++o<u;){var c=r[o],i=n?n(e[c],t[c],c,e,t):void 0;kt(e,c,void 0===i?t[c]:i)}return e}function Rt(t,r){var e,n,o=t.__data__;return("string"==(n=typeof(e=r))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==e:null===e)?o["string"==typeof r?"string":"hash"]:o.map}function Ut(t,r){var e=function(t,r){return null==t?void 0:t[r]}(t,r);return Nt(e)?e:void 0}St.prototype.clear=function(){this.__data__=bt?bt(null):{}},St.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},St.prototype.get=function(t){var r=this.__data__;if(bt){var e=r[t];return e===o?void 0:e}return Z.call(r,t)?r[t]:void 0},St.prototype.has=function(t){var r=this.__data__;return bt?void 0!==r[t]:Z.call(r,t)},St.prototype.set=function(t,r){return this.__data__[t]=bt&&void 0===r?o:r,this},xt.prototype.clear=function(){this.__data__=[]},xt.prototype.delete=function(t){var r=this.__data__,e=Ft(r,t);return!(e<0||(e==r.length-1?r.pop():at.call(r,e,1),0))},xt.prototype.get=function(t){var r=this.__data__,e=Ft(r,t);return e<0?void 0:r[e][1]},xt.prototype.has=function(t){return Ft(this.__data__,t)>-1},xt.prototype.set=function(t,r){var e=this.__data__,n=Ft(e,t);return n<0?e.push([t,r]):e[n][1]=r,this},$t.prototype.clear=function(){this.__data__={hash:new St,map:new(yt||xt),string:new St}},$t.prototype.delete=function(t){return Rt(this,t).delete(t)},$t.prototype.get=function(t){return Rt(this,t).get(t)},$t.prototype.has=function(t){return Rt(this,t).has(t)},$t.prototype.set=function(t,r){return Rt(this,t).set(t,r),this},Et.prototype.clear=function(){this.__data__=new xt},Et.prototype.delete=function(t){return this.__data__.delete(t)},Et.prototype.get=function(t){return this.__data__.get(t)},Et.prototype.has=function(t){return this.__data__.has(t)},Et.prototype.set=function(t,r){var e=this.__data__;if(e instanceof xt){var o=e.__data__;if(!yt||o.length<n-1)return o.push([t,r]),this;e=this.__data__=new $t(o)}return e.set(t,r),this};var Wt=ft?V(ft,Object):function(){return[]},Ct=function(t){return tt.call(t)};function Dt(t,r){return!!(r=null==r?u:r)&&("number"==typeof t||F.test(t))&&t>-1&&t%1==0&&t<r}function Tt(t){var r=t&&t.constructor;return t===("function"==typeof r&&r.prototype||J)}function zt(t){if(null!=t){try{return Y.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Lt(t,r){return t===r||t!=t&&r!=r}(pt&&Ct(new pt(new ArrayBuffer(1)))!=j||yt&&Ct(new yt)!=l||ht&&"[object Promise]"!=Ct(ht.resolve())||dt&&Ct(new dt)!=d||vt&&"[object WeakMap]"!=Ct(new vt))&&(Ct=function(t){var r=tt.call(t),e=r==y?t.constructor:void 0,n=e?zt(e):void 0;if(n)switch(n){case _t:return j;case jt:return l;case gt:return"[object Promise]";case Ot:return d;case wt:return"[object WeakMap]"}return r});var Vt=Array.isArray;function Gt(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=u}(t.length)&&!qt(t)}var Kt=st||function(){return!1};function qt(t){var r=Ht(t)?tt.call(t):"";return r==f||r==s}function Ht(t){var r=typeof t;return!!t&&("object"==r||"function"==r)}function Jt(t){return Gt(t)?Pt(t):function(t){if(!Tt(t))return lt(t);var r=[];for(var e in Object(t))Z.call(t,e)&&"constructor"!=e&&r.push(e);return r}(t)}r.exports=function(t){return It(t,!0,!0)}}(W={exports:{}},W.exports),W.exports);const T=Array.isArray;function z(t){return"string"==typeof t&&t.length>0&&"."===t[0]?t.slice(1):t}function L(t,r){return function t(r,e,n){const o=D(r);let u,c,i,a,f;if((n=Object.assign({depth:-1,path:""},n)).depth+=1,T(o))for(u=0,c=o.length;u<c;u++){const r=`${n.path}.${u}`;void 0!==o[u]?(n.parent=D(o),i=t(e(o[u],void 0,Object.assign({},n,{path:z(r)})),e,Object.assign({},n,{path:z(r)})),Number.isNaN(i)&&u<o.length?(o.splice(u,1),u-=1):o[u]=i):o.splice(u,1)}else if(C(o))for(u=0,c=(a=Object.keys(o)).length;u<c;u++){f=a[u];const r=`${n.path}.${f}`;0===n.depth&&null!=f&&(n.topmostKey=f),n.parent=D(o),i=t(e(f,o[f],Object.assign({},n,{path:z(r)})),e,Object.assign({},n,{path:z(r)})),Number.isNaN(i)?delete o[f]:o[f]=i}return o}(t,r,{})}return function(t){function r(t){return"string"==typeof t}var e=Array.isArray,n=!0;return!!(e(t)||C(t)||r(t))&&(r(t)?0===$(t).length:(t=L(t,function(t,e){var o=void 0!==e?e:t;return r(o)&&""!==$(o)&&(n=!1),o}),n))}}); |
{ | ||
"name": "ast-contains-only-empty-space", | ||
"version": "1.3.3", | ||
"version": "1.4.0", | ||
"description": "Returns Boolean depending if passed AST contain only empty space", | ||
@@ -29,6 +29,5 @@ "license": "MIT", | ||
"format": "prettier '*.{js,ts,css,less,scss,vue,gql,md}' --write && ./node_modules/.bin/eslint src/*.js test/*.js --fix", | ||
"precommit": "npm run format && npm test", | ||
"prepare": "npm run build", | ||
"pretest": "npm run build", | ||
"test": "./node_modules/.bin/eslint src/*.js test/*.js && nyc --require esm --reporter=html --reporter=text ava" | ||
"test": "./node_modules/.bin/eslint src/*.js test/*.js && nyc ava" | ||
}, | ||
@@ -142,3 +141,5 @@ "ava": { | ||
"licence": { | ||
"extras": [] | ||
"extras": [ | ||
"" | ||
] | ||
}, | ||
@@ -160,4 +161,11 @@ "npmignore": { | ||
}, | ||
"nyc": { | ||
"instrument": false, | ||
"require": [ | ||
"@babel/register" | ||
], | ||
"sourceMap": false | ||
}, | ||
"dependencies": { | ||
"ast-monkey-traverse": "^1.3.2", | ||
"ast-monkey-traverse": "^1.3.3", | ||
"lodash.isplainobject": "*", | ||
@@ -167,5 +175,7 @@ "lodash.trim": "*" | ||
"devDependencies": { | ||
"ava": "latest", | ||
"babel-preset-env": "latest", | ||
"codacy-coverage": "latest", | ||
"@babel/core": "^7.1.2", | ||
"@babel/preset-env": "^7.1.0", | ||
"@babel/register": "^7.0.0", | ||
"ava": "1.0.0-beta.8", | ||
"babel-plugin-istanbul": "^5.0.1", | ||
"coveralls": "latest", | ||
@@ -180,3 +190,2 @@ "eslint": "latest", | ||
"eslint-plugin-scanjs-rules": "latest", | ||
"esm": "latest", | ||
"husky": "latest", | ||
@@ -186,8 +195,9 @@ "nyc": "latest", | ||
"rollup": "latest", | ||
"rollup-plugin-babel": "^3.0.5", | ||
"rollup-plugin-commonjs": "^9.1.3", | ||
"rollup-plugin-node-resolve": "^3.3.0", | ||
"rollup-plugin-strip": "^1.1.1", | ||
"rollup-plugin-uglify": "^4.0.0" | ||
"rollup-plugin-babel": "^4.0.3", | ||
"rollup-plugin-cleanup": "^3.0.0", | ||
"rollup-plugin-commonjs": "^9.2.0", | ||
"rollup-plugin-node-resolve": "^3.4.0", | ||
"rollup-plugin-strip": "^1.2.0", | ||
"rollup-plugin-terser": "^3.0.0" | ||
} | ||
} |
@@ -40,5 +40,5 @@ # ast-contains-only-empty-space | ||
| ------------------------------------------------------------------------------------------------------- | --------------------- | ------------------------------------------- | ----- | | ||
| Main export - **CommonJS version**, transpiled to ES5, contains `require` and `module.exports` | `main` | `dist/ast-contains-only-empty-space.cjs.js` | 917 B | | ||
| **ES module** build that Webpack/Rollup understands. Untranspiled ES6 code with `import`/`export`. | `module` | `dist/ast-contains-only-empty-space.esm.js` | 722 B | | ||
| **UMD build** for browsers, transpiled, minified, containing `iife`'s and has all dependencies baked-in | `browser` | `dist/ast-contains-only-empty-space.umd.js` | 11 KB | | ||
| Main export - **CommonJS version**, transpiled to ES5, contains `require` and `module.exports` | `main` | `dist/ast-contains-only-empty-space.cjs.js` | 881 B | | ||
| **ES module** build that Webpack/Rollup understands. Untranspiled ES6 code with `import`/`export`. | `module` | `dist/ast-contains-only-empty-space.esm.js` | 686 B | | ||
| **UMD build** for browsers, transpiled, minified, containing `iife`'s and has all dependencies baked-in | `browser` | `dist/ast-contains-only-empty-space.umd.js` | 12 KB | | ||
@@ -45,0 +45,0 @@ **[⬆ back to top](#markdown-header-ast-contains-only-empty-space)** |
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
27357
97
24
Updatedast-monkey-traverse@^1.3.3