Skip to content

Instantly share code, notes, and snippets.

View johnny-shaman's full-sized avatar
:octocat:

Shinichi johnny-shaman

:octocat:
View GitHub Profile
@johnny-shaman
johnny-shaman / dsand.js
Last active October 25, 2018 03:07
It's on load hear minify js easly
this._.lib==="losand"&&(()=>{"use strict"; const $=_(function(n){return _((n.tagName!==undefined&&$[n.tagName]!==undefined)?$[n.tagName].prototype:$.prototype).create({n:{configurable:true,writable:true,value:n}})._;}).annex({end:{configurable:true,get(){return this.n;}},id:{configurable:true,value(id){return _(this).$(t=>(_($.id).set(this,id),_(t.n).draw({id})))._;}},"class":{configurable:true,value(...s){return _(this).$(t=>(s.each(k=>_($.class).draw({[k]:[this]})),_(t.n).draw({"class":s.join(" ")})))._;}},name:{configurable:true,value(name){return _(this).$(t=>(_($.name).set(this,name),_(t.n).draw({name})))._;}},"#":{configurable:true,get(){return this.id;}},".":{configurable:true,get(){return this.class;}},css:{configurable:true,value(o){return _(this).$(t=>_(t.n.style).draw(o.css))._;}},style:{configurable:true,value(o){return _(this).$(t=>_(t.n.style).draw(o.style))._;}},item:{configurable:true,value(o){return _(o).draw(_(o.item).keys.bind(a=>a.reduce((p,c)=>p.draw({[`item${c}`]:o.item[c]}),_({})))._);}
@johnny-shaman
johnny-shaman / losand.js
Last active October 25, 2018 03:06
It's on load hear minify js easly
(()=>{"use strict"; let _=function(v,a){return Object.create(_.prototype,{"@":{configurable:true,writable:true,value:v},re:{configurable:true,writable:true,value:a},cached:{configurable:true,writable:true,value:undefined}});}; Object.defineProperties(_.prototype,{by:{configurable:true,get(){return this.map(w=>w.constructor);}},be:{configurable:true,value(f,...v){return this.map(t=>f(t,...v)?t:undefined);}},is:{configurable:true,value(t){return this.be(v=>_(v).by._===t);}},isnt:{configurable:true,value(t){return this.be(v=>_(v).by._!==t);}},"":{configurable:true,get(){return this["@"]===undefined||this["@"]===null;}},fullen:{configurable:true,get(){return!(this.vals._.includes(undefined)||this.vals._.includes(null));}},join:{configurable:true,get(){return this[""]?this["@"]:this["@"].valueOf();}},_:{configurable:true,get(){return this.join;}},$:{configurable:true,value(f,...v){return this[""]?this:this.map(f,...v).re;}},$$:{configurable:true,value(f,...v){return this[""]?this:this.fit(f,...v).re;}},map:{config