(-main & args)Compile clojure script and run specs. args can be empty or have the type of command: auto (default) - watch files and recompiling and re-running affected specs once - compile and run specs (if enabled) once spec - just run the specs (assumes compilation is already done)
Compile clojure script and run specs. args can be empty or have the type of command: auto (default) - watch files and recompiling and re-running affected specs once - compile and run specs (if enabled) once spec - just run the specs (assumes compilation is already done)
(auto-run build-options)Runs cljs.build.api/watch in a loop while the running volatile is
true. Exceptions thrown by api/watch are printed and the loop restarts;
exceptions raised after a shutdown signal are logged briefly and dropped
to keep shutdown clean.
Runs `cljs.build.api/watch` in a loop while the `running` volatile is true. Exceptions thrown by `api/watch` are printed and the loop restarts; exceptions raised after a shutdown signal are logged briefly and dropped to keep shutdown clean.
(build-js-path)(build-reverse-deps deps)(build-spec-config)(build-spec-html)(build-spec-map rdeps deps timestamp)(config-with-defaults config)(configure! config build-key)Reads the EDN config map and the chosen build-key (e.g. :development) and
populates the runtime atoms (build-config, run-env, ns-prefix,
ignore-errors, ignore-consoles). Throws via resolve-build-config if
the build-key is missing, and throws if :ns-prefix is missing.
Called once from -main before compilation.
Reads the EDN config map and the chosen build-key (e.g. :development) and populates the runtime atoms (`build-config`, `run-env`, `ns-prefix`, `ignore-errors`, `ignore-consoles`). Throws via `resolve-build-config` if the build-key is missing, and throws if `:ns-prefix` is missing. Called once from `-main` before compilation.
(create-pw-resources)(find-updated-specs rdeps deps timestamp)(install-shutdown-hook!)Registers a JVM shutdown hook that calls shutdown! on the current
thread, so kill/Ctrl-C/parent-process-exit gracefully stops the
auto-run loop.
Registers a JVM shutdown hook that calls `shutdown!` on the current thread, so `kill`/Ctrl-C/parent-process-exit gracefully stops the auto-run loop.
(modified-time file)(monitor-stdin!)Spawns a daemon thread that reads stdin until EOF, then calls
shutdown!. Prevents orphaned subprocesses when the parent process
closes stdin (e.g. agent harnesses that don't propagate signals).
Spawns a daemon thread that reads stdin until EOF, then calls `shutdown!`. Prevents orphaned subprocesses when the parent process closes stdin (e.g. agent harnesses that don't propagate signals).
(on-console m)(on-dev-compiled)Watch-fn callback for ClojureScript auto-compilation. Resets the error
atom, touches the .specljs-timestamp file, touches the JS output file
so the browser reloads it, then re-runs only the affected specs.
Watch-fn callback for ClojureScript auto-compilation. Resets the error atom, touches the `.specljs-timestamp` file, touches the JS output file so the browser reloads it, then re-runs only the affected specs.
(on-error error)(print-error-summary {:keys [exit-if-errors?] :as settings})(project-ns? ns)(rdeps-affected-by rdeps updated)(run-specs & {:keys [timestamp auto?]})Launches Playwright, navigates to the generated specs.html, and runs the
ClojureScript Speclj suite. With :auto? true, only specs affected by
changes since :timestamp are run; otherwise, runs the full suite and
exits the JVM with the Speclj status code. Always closes browser and
Playwright resources on exit.
Launches Playwright, navigates to the generated specs.html, and runs the ClojureScript Speclj suite. With `:auto? true`, only specs affected by changes since `:timestamp` are run; otherwise, runs the full suite and exits the JVM with the Speclj status code. Always closes browser and Playwright resources on exit.
(run-specs-auto page timestamp)(run-specs-once page)(shutdown! main-thread)Sets running to false and interrupts the given thread. Used by both
the JVM shutdown hook and the stdin monitor to stop the auto-run loop.
Sets `running` to false and interrupts the given thread. Used by both the JVM shutdown hook and the stdin monitor to stop the auto-run loop.
(spec-html-url)(timestamp! file)(timestamp-file)cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |