Some convenience macros for situations when you want to call toolbox functions optionally under :advanced mode.
Some convenience macros for situations when you want to call toolbox functions optionally under :advanced mode.
(envelope & args)
(envelope obj)
(envelope obj header)
(envelope obj header style)
(envelope obj header style tag)
This is a simple wrapper for logging "busy" objects. This is especially handy when you happen to be logging javascript objects with many properties. Standard javascript console renderer tends to print a lot of infomation in the header in some cases and that can make console output pretty busy. By using envelope you can force your own short header and let the details expand on demand via disclosure triangle. The header can be styled and you can optionally specify preferred wrapping tag (advanced).
This is a simple wrapper for logging "busy" objects. This is especially handy when you happen to be logging javascript objects with many properties. Standard javascript console renderer tends to print a lot of infomation in the header in some cases and that can make console output pretty busy. By using envelope you can force your own short header and let the details expand on demand via disclosure triangle. The header can be styled and you can optionally specify preferred wrapping tag (advanced).
(force-format obj)
Forces object to be rendered by cljs-devtools during console logging.
Unfortunately custom formatters subsystem in DevTools is not applied to primitive values like numbers, strings, null, etc. This wrapper can be used as a workaround if you really need to force cljs-devtools rendering:
(.log js/console nil) ; will render 'null' (.log js/console (force-format nil)) ; will render 'nil' and not 'null'
Forces object to be rendered by cljs-devtools during console logging. Unfortunately custom formatters subsystem in DevTools is not applied to primitive values like numbers, strings, null, etc. This wrapper can be used as a workaround if you really need to force cljs-devtools rendering: (.log js/console nil) ; will render 'null' (.log js/console (force-format nil)) ; will render 'nil' and not 'null' See https://github.com/binaryage/cljs-devtools/issues/17
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close