descendants
(descendants tag)
(descendants h tag)
See Also:
Source docstring:
Returns the immediate and indirect children of tag, through a
relationship established via derive. h must be a hierarchy obtained
from make-hierarchy, if not supplied defaults to the global
hierarchy. Note: does not work on JavaScript type inheritance
relationships.
(defn descendants
([tag] (descendants @(get-global-hierarchy) tag))
([h tag]
(if (js-fn? tag)
(throw (js/Error. "Can't get descendants of constructors"))
(not-empty (get (:descendants h) tag)))))