Liking cljdoc? Tell your friends :D
Clojure only.

lucid.publish.collect.api


collect-apisclj

(collect-apis {:keys [articles project] :as interim} name)

gets all the api tags in the document

(let [project (project/project) project (assoc project :lookup (project/file-lookup project)) elems (parse/parse-file "test/documentation/lucid_core.clj" project) bundle {:articles {"lucid-core" {:elements elems}} :references {} :project project}] (with-redefs [reference/reference-namespaces (fn [_ _ namespaces] namespaces)] (-> (collect-apis bundle "lucid-core") :references))) => '[lucid.core.asm lucid.core.code lucid.core.debug lucid.core.inject lucid.core.java lucid.core.namespace]

gets all the `api` tags in the document

(let [project (project/project)
      project (assoc project :lookup (project/file-lookup project))
      elems   (parse/parse-file "test/documentation/lucid_core.clj" project)
      bundle  {:articles {"lucid-core" {:elements elems}}
               :references {}
               :project project}]
 (with-redefs [reference/reference-namespaces (fn [_ _ namespaces] namespaces)]
    (-> (collect-apis bundle "lucid-core")
        :references)))
=> '[lucid.core.asm lucid.core.code lucid.core.debug
     lucid.core.inject lucid.core.java lucid.core.namespace]
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close