Liking cljdoc? Tell your friends :D

std.lang.base.library-load


analyze-fileclj

(analyze-file filepath)

Analyzes a file to find namespace and dependencies.

Analyzes a file to find namespace and dependencies.
raw docstring

analyze-stringclj

(analyze-string content)

Analyzes code string to find namespace and dependencies. Returns a map with :ns, :requires (Clojure), and :std-requires (std.lang).

Analyzes code string to find namespace and dependencies.
Returns a map with :ns, :requires (Clojure), and :std-requires (std.lang).
raw docstring

clone-and-loadclj

(clone-and-load filepath)

Clones the default library and loads the given file into it. Useful for comparing versions.

Clones the default library and loads the given file into it.
Useful for comparing versions.
raw docstring

create-dependency-graphclj

(create-dependency-graph files)

Creates a dependency graph from a list of files. Returns a map where keys are namespaces and values are sets of dependencies.

Creates a dependency graph from a list of files.
Returns a map where keys are namespaces and values are sets of dependencies.
raw docstring

eval-in-libraryclj

(eval-in-library form lib-instance ns-sym)

Evaluates a form within the context of a specific library instance. Handles l/script specially to register modules in the provided library. Injects module metadata for other forms to ensure correct registration without relying on global runtime state.

Evaluates a form within the context of a specific library instance.
Handles `l/script` specially to register modules in the provided library.
Injects module metadata for other forms to ensure correct registration without relying on global runtime state.
raw docstring

load-file-into-libraryclj

(load-file-into-library filepath lib-instance)

Loads a file into a specific library instance.

Loads a file into a specific library instance.
raw docstring

load-namespaceclj

(load-namespace lib-instance root-ns & [opts])

Recursively loads a namespace and its dependencies into the library.

args: lib-instance - The library to load into. root-ns - The root namespace symbol to start loading from. opts - Options map. :loaded - Atom containing a set of already loaded namespaces. :project - Project map for resolving paths (defaults to code.project/project).

Returns the library instance.

Recursively loads a namespace and its dependencies into the library.

args:
  lib-instance - The library to load into.
  root-ns      - The root namespace symbol to start loading from.
  opts         - Options map.
    :loaded    - Atom containing a set of already loaded namespaces.
    :project   - Project map for resolving paths (defaults to code.project/project).

Returns the library instance.
raw docstring

load-string-into-libraryclj

(load-string-into-library content lib-instance initial-ns-sym)

Loads code from a string into a specific library instance. Tracks namespace changes via ns forms.

Note: This function performs standard entry hydration (via create-code-hydrate) which resolves links and adds metadata as defined by the language grammar. However, it does NOT:

  1. Recursively load required files (file-level hydration).
  2. Initialize language runtimes (runtime hydration).
  3. Execute side effects outside of the library structure.
Loads code from a string into a specific library instance.
Tracks namespace changes via `ns` forms.

Note: This function performs standard entry hydration (via `create-code-hydrate`)
which resolves links and adds metadata as defined by the language grammar.
However, it does NOT:
1. Recursively load required files (file-level hydration).
2. Initialize language runtimes (runtime hydration).
3. Execute side effects outside of the library structure.
raw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close