Rebind this to false if you don't want to see ANSI codes in some part of your code.
Rebind this to false if you don't want to see ANSI codes in some part of your code.
(ansi & styles)
Output an ANSI escape code using a style key.
(ansi :blue) (ansi :underline) (ansi :underline :red :on-yellow)
Note, try (style-test-page) to see all available styles.
If use-ansi is bound to false, outputs an empty string instead of an ANSI code. You can use this to temporarily or permanently turn off ANSI color in some part of your program, while maintaining only 1 version of your marked-up text.
Output an ANSI escape code using a style key. (ansi :blue) (ansi :underline) (ansi :underline :red :on-yellow) Note, try (style-test-page) to see all available styles. If *use-ansi* is bound to false, outputs an empty string instead of an ANSI code. You can use this to temporarily or permanently turn off ANSI color in some part of your program, while maintaining only 1 version of your marked-up text.
(color-doc v)
A stylized version of clojure.core/doc.
A stylized version of clojure.core/doc.
(print-doc-color v)
Print stylized function documentation.
Print stylized function documentation.
(print-namespace-doc-color nspace)
Print stylized documentation for a namespace.
Print stylized documentation for a namespace.
(print-special-doc-color name type anchor)
Print stylized special form documentation.
Print stylized special form documentation.
(style s & styles)
Applies ANSI color and style to a text string.
(style "foo" :red) (style "foo" :red :underline) (style "foo" :red :on-blue :underline)
Applies ANSI color and style to a text string. (style "foo" :red) (style "foo" :red :underline) (style "foo" :red :on-blue :underline)
(style-test-page)
Print the list of supported ANSI styles, each style name shown with its own style.
Print the list of supported ANSI styles, each style name shown with its own style.
(with-ansi & code)
Runs the given code with the use-ansi variable temporarily bound to true, to enable the production of any ANSI color codes specified in the code.
Runs the given code with the use-ansi variable temporarily bound to true, to enable the production of any ANSI color codes specified in the code.
(without-ansi & code)
Runs the given code with the use-ansi variable temporarily bound to false, to suppress the production of any ANSI color codes specified in the code.
Runs the given code with the use-ansi variable temporarily bound to false, to suppress the production of any ANSI color codes specified in the code.
(wrap-style s wrapper & styles)
Wraps a base string with a stylized wrapper. If the wrapper is a string it will be placed on both sides of the base, and if it is a seq the first and second items will wrap the base.
To wrap debug with red brackets => [debug]:
(wrap-style "debug" ["[" "]"] :red)
Wraps a base string with a stylized wrapper. If the wrapper is a string it will be placed on both sides of the base, and if it is a seq the first and second items will wrap the base. To wrap debug with red brackets => [debug]: (wrap-style "debug" ["[" "]"] :red)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close