(merge-page-sources sources)
Merges collections of pages ensuring every path only occurs once across all collections.
Takes a map of collection name to page collection, and returns a map of path to content. The collection names are only used for error reporting.
For example,
(merge-page-sources
{:person-pages (create-person-pages)
:article-pages (create-article-pages)
:general-pages (create-general-pages)})
Merges collections of pages ensuring every path only occurs once across all collections. Takes a map of collection name to page collection, and returns a map of path to content. The collection names are only used for error reporting. For example, (merge-page-sources {:person-pages (create-person-pages) :article-pages (create-article-pages) :general-pages (create-general-pages)})
(slurp-directory dir regexp & opts)
Returns a map of paths to file contents in the dir
. dir
should be
accessible via clojure.java.io/as-file
. regexp
will be used to filter the
files. opts
are passed to slurp
to enable specification of encoding and
buffer-size etc.
Returns a map of paths to file contents in the `dir`. `dir` should be accessible via `clojure.java.io/as-file`. `regexp` will be used to filter the files. `opts` are passed to `slurp` to enable specification of encoding and buffer-size etc.
(slurp-resources dir regexp & opts)
Returns a map of paths to file contents in the dir
found on the resource
path. regexp
will be used to filter the files. opts
are passed to slurp
to enable specification of encoding and buffer-size etc.
Returns a map of paths to file contents in the `dir` found on the resource path. `regexp` will be used to filter the files. `opts` are passed to `slurp` to enable specification of encoding and buffer-size etc.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close