A Clojure namespace dependency analyzer.
To run clj-depend from Leiningen, check lein-clj-depend plugin.
You can use the namespace clj-depend.api to have access to all clj-depend features.
To let clj-depend know the existing layers in your application and the allowed dependencies between these layers, create a .clj-depend
directory at the root of the project and inside it a config.edn
file.
Diagram to exemplify the dependency between layers:
graph TD
A[foo.controller] --> B[foo.logic]
A --> C[foo.model]
B --> C
Configuration file (.clj-depend/config.edn
) for diagram above:
{:source-paths #{"src"}
:layers {:controller {:defined-by ".*\\.controller\\..*"
:accessed-by-layers #{}}
:logic {:defined-by ".*\\.logic\\..*"
:accessed-by-layers #{:controller}}
:model {:defined-by ".*\\.model\\..*"
:accessed-by-layers #{:logic :controller}}}}
Can you improve this documentation? These fine people already did:
Fábio Domingues & Fabio DominguesEdit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close