-
Notifications
You must be signed in to change notification settings - Fork 4
/
tag.min.js
1 lines (1 loc) · 1.12 KB
/
tag.min.js
1
!function(t){function n(e){if(i[e])return i[e].exports;var o=i[e]={exports:{},id:e,loaded:!1};return t[e].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}var i={};return n.m=t,n.c=i,n.p="",n(0)}([function(t,n,i){"use strict";function e(t){return t.chain.init=t.chain.init||t.chain.set,o(t),r(t),t}var o=i(1),r=i(3);"undefined"!=typeof window&&window.Gun&&e(window.Gun),t.exports=e},function(t,n,i){"use strict";function e(t){return"object"!=typeof t?(console.log("Only objects can be tagged"),!0):void 0}function o(t,n){t.get(u+n).val(function(i){t.get(u+"all tags").init().path(n).put(i)})}function r(t,n){return n=Array.prototype.slice.call(n),n.forEach(function(n){t.tag(n)}),t}var u=i(2);t.exports=function(t){t.chain.tag=function(t){return 1!==arguments.length?r(this,arguments):this.val(function(n){return e(n)?this:(this.get(u+t).init().path(n._["#"]).put(n),void o(this,t))})}}},function(t,n){t.exports="xWVyuulvIIHyTO08nHHWrqta:"},function(t,n,i){"use strict";var e=i(2);t.exports=function(t){t.chain.tagged=function(t,n){return 0===arguments.length?this.get(e+"all tags"):t||"string"==typeof t?this.get(e+t).map(n,!0):this}}}]);