["^ ","~:rename-macros",["^ "],"~:renames",["^ "],"~:externs",["^ ","~$Error",["^ "]],"~:use-macros",["^ ","~$reagent-id","~$re-frame.interop","~$console","~$re-frame.loggers","~$dispose!","^6","~$add-on-dispose!","^6","~$make-reaction","^6","~$deref?","^6","~$ratom?","^6","~$debug-enabled?","^6"],"~:excludes",["~#set",[]],"~:name","~$re-frame.subs","~:imports",null,"~:requires",["^ ","~$re-frame.db","^E","^6","^6","^8","^8","~$re-frame.utils","^F","~$re-frame.registrar","^G","~$trace","~$re-frame.trace","^I","^I"],"~:cljs.spec/speced-vars",[],"~:uses",["^ ","^5","^6","^7","^8","~$app-db","^E","^9","^6","^:","^6","^;","^6","~$get-handler","^G","~$first-in-vector","^F","^<","^6","^=","^6","^>","^6","~$clear-handlers","^G","~$register-handler","^G"],"~:defs",["^ ","~$to-seq",["^ ","~:protocol-inline",null,"~:meta",["^ ","~:file","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","~:line",181,"~:column",7,"~:end-line",181,"~:end-column",13,"~:arglists",["~#list",["~$quote",["^[",[["~$x"]]]]],"~:doc","Coerces x to a seq if it isn't one already"],"^A","~$re-frame.subs/to-seq","~:variadic",false,"^U","out-cli/re_frame/subs.cljc","^Y",13,"~:method-params",["^[",[["~$x"]]],"~:protocol-impl",null,"~:arglists-meta",["^[",[null,null]],"^W",1,"^V",181,"^X",181,"~:max-fixed-arity",1,"~:fn-var",true,"^Z",["^[",["^10",["^[",[["~$x"]]]]],"^11","Coerces x to a seq if it isn't one already"],"~$cache-and-return",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",42,"^W",7,"^X",42,"^Y",23,"^Z",["^[",["^10",["^[",[["~$query-v","~$dynv","~$r"]]]]],"^11","cache the reaction r"],"^A","~$re-frame.subs/cache-and-return","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",23,"^14",["^[",[["^1:","^1;","~$r"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",42,"^X",42,"^17",3,"^18",true,"^Z",["^[",["^10",["^[",[["^1:","^1;","~$r"]]]]],"^11","cache the reaction r"],"~$deref-input-signals",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",188,"^W",8,"^X",188,"^Y",27,"~:private",true,"^Z",["^[",["^10",["^[",[["~$signals","~$query-id"]]]]]],"^1>",true,"^A","~$re-frame.subs/deref-input-signals","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",27,"^14",["^[",[["^1?","^1@"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",188,"^X",188,"^17",2,"^18",true,"^Z",["^[",["^10",["^[",[["^1?","^1@"]]]]]],"~$subscribe",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",74,"^W",7,"^X",74,"^Y",16,"^Z",["^[",["^10",["^[",[["~$query"],["^1C","^1;"]]]]],"^11","Given a `query`, returns a Reagent `reaction` which, over\n  time, reactively delivers a stream of values. So in FRP-ish terms,\n  it returns a Signal.\n\n  To obtain the returned Signal/Stream's current value, it must be `deref`ed.\n\n  `query` is a vector of at least one element. The first element is the\n  `query-id`, typically a namespaced keyword. The rest of the vector's\n  elements are optional, additional values which parameterise the query\n  performed.\n\n  `dynv` is an optional 3rd argument, `which is a vector of further input\n  signals (atoms, reactions, etc), NOT values. This argument exists for\n  historical reasons and is borderline deprecated these days.\n\n  Example Usage:\n  --------------\n\n    (subscribe [:items])\n    (subscribe [:items \"blue\" :small])\n    (subscribe [:items {:colour \"blue\"  :size :small}])\n\n  Note: for any given call to `subscribe` there must have been a previous call\n  to `reg-sub`, registering the query handler (function) for the `query-id` given.\n\n  Hint\n  ----\n\n  When used in a view function BE SURE to `deref` the returned value.\n  In fact, to avoid any mistakes, some prefer to define:\n\n     (def <sub  (comp deref re-frame.core/subscribe))\n\n  And then, within their views, they call  `(<sub [:items :small])` rather\n  than using `subscribe` directly.\n\n  De-duplication\n  --------------\n\n  XXX\n  ","~:top-fn",["^ ","^13",false,"^17",2,"^14",["^[",[["^1C"],["^1C","^1;"]]],"^Z",["^[",[["^1C"],["^1C","^1;"]]],"^16",["^[",[null,null]]]],"^A","~$re-frame.subs/subscribe","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",16,"^1D",["^ ","^13",false,"^17",2,"^14",["^[",[["^1C"],["^1C","^1;"]]],"^Z",["^[",[["^1C"],["^1C","^1;"]]],"^16",["^[",[null,null]]],"^14",["^[",[["^1C"],["^1C","^1;"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",74,"^X",74,"^17",2,"^18",true,"^Z",["^[",[["^1C"],["^1C","^1;"]]],"^11","Given a `query`, returns a Reagent `reaction` which, over\n  time, reactively delivers a stream of values. So in FRP-ish terms,\n  it returns a Signal.\n\n  To obtain the returned Signal/Stream's current value, it must be `deref`ed.\n\n  `query` is a vector of at least one element. The first element is the\n  `query-id`, typically a namespaced keyword. The rest of the vector's\n  elements are optional, additional values which parameterise the query\n  performed.\n\n  `dynv` is an optional 3rd argument, `which is a vector of further input\n  signals (atoms, reactions, etc), NOT values. This argument exists for\n  historical reasons and is borderline deprecated these days.\n\n  Example Usage:\n  --------------\n\n    (subscribe [:items])\n    (subscribe [:items \"blue\" :small])\n    (subscribe [:items {:colour \"blue\"  :size :small}])\n\n  Note: for any given call to `subscribe` there must have been a previous call\n  to `reg-sub`, registering the query handler (function) for the `query-id` given.\n\n  Hint\n  ----\n\n  When used in a view function BE SURE to `deref` the returned value.\n  In fact, to avoid any mistakes, some prefer to define:\n\n     (def <sub  (comp deref re-frame.core/subscribe))\n\n  And then, within their views, they call  `(<sub [:items :small])` rather\n  than using `subscribe` directly.\n\n  De-duplication\n  --------------\n\n  XXX\n  "],"~$reg-sub",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",200,"^W",7,"^X",200,"^Y",14,"^Z",["^[",["^10",["^[",[["^1@","~$&","~$args"]]]]],"^11","For a given `query-id`, register a `computation` function and input `signals`.\n\n  At an abstract level, a call to this function allows you to register 'the mechanism'\n  to later fulfil a call to `(subscribe [query-id ...])`.\n\n  To say that another way, reg-sub allows you to create a template for a node\n  in the signal graph. But note: reg-sub does not cause a node to be created.\n  It simply allows you to register the template from which such a\n  node could be created, if it were needed, sometime later, when the call\n  to `subscribe` is made.\n\n  reg-sub needs three things:\n    - a `query-id`\n    - the required inputs for this node\n    - a computation function for this node\n\n  The `query-id` is always the 1st argument to reg-sub and it is typically\n  a namespaced keyword.\n\n  A computation function is always the last argument and it has this general form:\n    `(input-signals, query-vector) -> a-value`\n\n  What goes in between the 1st and last args can vary, but whatever is there will\n  define the input signals part of the template, and, as a result, it will control\n  what values the computation functions gets as a first argument.\n\n  There's 3 ways this function can be called - 3 ways to supply input signals:\n\n  1. No input signals given:\n\n     (reg-sub\n       :query-id\n       a-computation-fn)   ;; (fn [db v]  ... a-value)\n\n     The node's input signal defaults to `app-db`, and the value within `app-db` is\n     is given as the 1st argument to the computation function.\n\n  2. A signal function is supplied:\n\n     (reg-sub\n       :query-id\n       signal-fn     ;; <-- here\n       computation-fn)\n\n     When a node is created from the template, the `signal-fn` will be called and it\n     is expected to return the input signal(s) as either a singleton, if there is only\n     one, or a sequence if there are many, or a map with the signals as the values.\n\n     The values from the nominated signals will be supplied as the 1st argument to the\n     computation function - either a singleton, sequence or map of them, paralleling\n     the structure returned by the signal function.\n\n     Here, is an example signal-fn, which returns a vector of input signals.\n\n       (fn [query-vec dynamic-vec]\n         [(subscribe [:a-sub])\n          (subscribe [:b-sub])])\n\n     For that signal function, the computation function must be written\n     to expect a vector of values for its first argument.\n       (fn [[a b] _] ....)\n\n     If the signal function was simpler and returned a singleton, like this:\n        (fn [query-vec dynamic-vec]\n          (subscribe [:a-sub]))\n\n     then the computation function must be written to expect a single value\n     as the 1st argument:\n\n        (fn [a _] ...)\n\n  3. Syntax Sugar\n\n     (reg-sub\n       :a-b-sub\n       :<- [:a-sub]\n       :<- [:b-sub]\n       (fn [[a b] [_]] {:a a :b b}))\n\n  This 3rd variation is syntactic sugar for the 2nd. Pairs are supplied instead\n  of an `input signals` functions. Each pair starts with a `:<-` and a subscription\n  vector follows.\n\n  For further understanding, read `/docs`, and look at the detailed comments in\n  /examples/todomvc/src/subs.cljs\n  ","^1D",["^ ","^13",true,"^17",1,"^14",[["^[",["^1@","^1G"]]],"^Z",["^[",[["^1@","~$&","^1G"]]],"^16",["^[",[null]]]],"^A","~$re-frame.subs/reg-sub","^13",true,"^U","out-cli/re_frame/subs.cljc","^Y",14,"^1D",["^ ","^13",true,"^17",1,"^14",[["^[",["^1@","^1G"]]],"^Z",["^[",[["^1@","~$&","^1G"]]],"^16",["^[",[null]]],"^14",[["^[",["^1@","^1G"]]],"^15",null,"^16",["^[",[null]],"^W",1,"^V",200,"^X",200,"^17",1,"^18",true,"^Z",["^[",[["^1@","~$&","^1G"]]],"^11","For a given `query-id`, register a `computation` function and input `signals`.\n\n  At an abstract level, a call to this function allows you to register 'the mechanism'\n  to later fulfil a call to `(subscribe [query-id ...])`.\n\n  To say that another way, reg-sub allows you to create a template for a node\n  in the signal graph. But note: reg-sub does not cause a node to be created.\n  It simply allows you to register the template from which such a\n  node could be created, if it were needed, sometime later, when the call\n  to `subscribe` is made.\n\n  reg-sub needs three things:\n    - a `query-id`\n    - the required inputs for this node\n    - a computation function for this node\n\n  The `query-id` is always the 1st argument to reg-sub and it is typically\n  a namespaced keyword.\n\n  A computation function is always the last argument and it has this general form:\n    `(input-signals, query-vector) -> a-value`\n\n  What goes in between the 1st and last args can vary, but whatever is there will\n  define the input signals part of the template, and, as a result, it will control\n  what values the computation functions gets as a first argument.\n\n  There's 3 ways this function can be called - 3 ways to supply input signals:\n\n  1. No input signals given:\n\n     (reg-sub\n       :query-id\n       a-computation-fn)   ;; (fn [db v]  ... a-value)\n\n     The node's input signal defaults to `app-db`, and the value within `app-db` is\n     is given as the 1st argument to the computation function.\n\n  2. A signal function is supplied:\n\n     (reg-sub\n       :query-id\n       signal-fn     ;; <-- here\n       computation-fn)\n\n     When a node is created from the template, the `signal-fn` will be called and it\n     is expected to return the input signal(s) as either a singleton, if there is only\n     one, or a sequence if there are many, or a map with the signals as the values.\n\n     The values from the nominated signals will be supplied as the 1st argument to the\n     computation function - either a singleton, sequence or map of them, paralleling\n     the structure returned by the signal function.\n\n     Here, is an example signal-fn, which returns a vector of input signals.\n\n       (fn [query-vec dynamic-vec]\n         [(subscribe [:a-sub])\n          (subscribe [:b-sub])])\n\n     For that signal function, the computation function must be written\n     to expect a vector of values for its first argument.\n       (fn [[a b] _] ....)\n\n     If the signal function was simpler and returned a singleton, like this:\n        (fn [query-vec dynamic-vec]\n          (subscribe [:a-sub]))\n\n     then the computation function must be written to expect a single value\n     as the 1st argument:\n\n        (fn [a _] ...)\n\n  3. Syntax Sugar\n\n     (reg-sub\n       :a-b-sub\n       :<- [:a-sub]\n       :<- [:b-sub]\n       (fn [[a b] [_]] {:a a :b b}))\n\n  This 3rd variation is syntactic sugar for the 2nd. Pairs are supplied instead\n  of an `input signals` functions. Each pair starts with a `:<-` and a subscription\n  vector follows.\n\n  For further understanding, read `/docs`, and look at the detailed comments in\n  /examples/todomvc/src/subs.cljs\n  "],"~$query->reaction",["^ ","^A","~$re-frame.subs/query->reaction","^U","out-cli/re_frame/subs.cljc","^V",18,"^W",1,"^X",18,"^Y",21,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",18,"^W",6,"^X",18,"^Y",21],"~:tag","~$any"],"~$clear-all-handlers!",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",36,"^W",7,"^X",36,"^Y",26,"^Z",["^[",["^10",["^[",[[]]]]],"^11","Unregisters all existing subscription handlers"],"^A","~$re-frame.subs/clear-all-handlers!","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",26,"^14",["^[",[[]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",36,"^X",36,"^17",0,"^18",true,"^Z",["^[",["^10",["^[",[[]]]]],"^11","Unregisters all existing subscription handlers"],"~$cache-lookup",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",65,"^W",7,"^X",65,"^Y",19,"^Z",["^[",["^10",["^[",[["^1:"],["^1:","~$dyn-v"]]]]],"^1D",["^ ","^13",false,"^17",2,"^14",["^[",[["^1:"],["^1:","^1P"]]],"^Z",["^[",[["^1:"],["^1:","^1P"]]],"^16",["^[",[null,null]]]],"^A","~$re-frame.subs/cache-lookup","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",19,"^1D",["^ ","^13",false,"^17",2,"^14",["^[",[["^1:"],["^1:","^1P"]]],"^Z",["^[",[["^1:"],["^1:","^1P"]]],"^16",["^[",[null,null]]],"^14",["^[",[["^1:"],["^1:","^1P"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",65,"^X",65,"^17",2,"^18",true,"^Z",["^[",[["^1:"],["^1:","^1P"]]]],"~$map-vals",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",163,"^W",8,"^X",163,"^Y",16,"^1>",true,"^Z",["^[",["^10",["^[",[["~$f","~$m"]]]]],"^11","Returns a new version of 'm' in which 'f' has been applied to each value.\n  (map-vals inc {:a 4, :b 2}) => {:a 5, :b 3}"],"^1>",true,"^A","~$re-frame.subs/map-vals","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",16,"^14",["^[",[["~$f","~$m"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",163,"^X",163,"^17",2,"^18",true,"^Z",["^[",["^10",["^[",[["~$f","~$m"]]]]],"^11","Returns a new version of 'm' in which 'f' has been applied to each value.\n  (map-vals inc {:a 4, :b 2}) => {:a 5, :b 3}"],"~$kind",["^ ","^A","~$re-frame.subs/kind","^U","out-cli/re_frame/subs.cljc","^V",10,"^W",1,"^X",10,"^Y",10,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",10,"^W",6,"^X",10,"^Y",10],"^1K","~$cljs.core/Keyword"],"~$clear-subscription-cache!",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",20,"^W",7,"^X",20,"^Y",32,"^Z",["^[",["^10",["^[",[[]]]]],"^11","Causes all subscriptions to be removed from the cache.\n  Does this by:\n     1. running on-dispose on all cached subscriptions\n     2. These on-dispose will then do the removal of themselves.\n\n  This is a development time tool. Useful when reloading Figwheel code\n  after a React exception, because React components won't have been\n  cleaned up properly. And this, in turn, means the subscriptions within those\n  components won't have been cleaned up correctly. So this forces the issue."],"^A","~$re-frame.subs/clear-subscription-cache!","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",32,"^14",["^[",[[]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",20,"^X",20,"^17",0,"^18",true,"^Z",["^[",["^10",["^[",[[]]]]],"^11","Causes all subscriptions to be removed from the cache.\n  Does this by:\n     1. running on-dispose on all cached subscriptions\n     2. These on-dispose will then do the removal of themselves.\n\n  This is a development time tool. Useful when reloading Figwheel code\n  after a React exception, because React components won't have been\n  cleaned up properly. And this, in turn, means the subscriptions within those\n  components won't have been cleaned up correctly. So this forces the issue."],"~$map-signals",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_frame/subs.cljc","^V",171,"^W",7,"^X",171,"^Y",18,"^Z",["^[",["^10",["^[",[["~$f","^1?"]]]]],"^11","Runs f over signals. Signals may take several\n  forms, this function handles all of them."],"^A","~$re-frame.subs/map-signals","^13",false,"^U","out-cli/re_frame/subs.cljc","^Y",18,"^14",["^[",[["~$f","^1?"]]],"^15",null,"^16",["^[",[null,null]],"^W",1,"^V",171,"^X",171,"^17",2,"^18",true,"^Z",["^[",["^10",["^[",[["~$f","^1?"]]]]],"^11","Runs f over signals. Signals may take several\n  forms, this function handles all of them."]],"~:cljs.spec/registry-ref",[],"~:require-macros",["^ ","^H","^I","^I","^I"],"~:cljs.analyzer/constants",["^ ","~:seen",["^@",["~:dyn-v","~:tags","~:sub/run","~:else","~:<-","~:sub","~:sub/create","~:warn","~:value","~:operation","~:start","~:duration","~:query-v","~:cached?","~:sub/dispose","~:error","~:input-signals","~:end","~:reaction","~:op-type"]],"~:order",["^28","^2:","^2<","^2F","^24","^2A","^2?","^2E","^2=","^2>","^2D","^29","^2@","^2B","^23","^26","^2C","^27","^25","^2;"]],"^11",null]