(cljs? env)Take the &env from a macro, and tell whether we are expanding into CLJS.
Take the &env from a macro, and tell whether we are expanding into CLJS.
Platform specific converters.
Takes the env (from &env or platform keyword) and returns a converter function.
The converter function takes a symbol and returns the platform specific version of that symbol.
Platform specific converters. Takes the `env` (from `&env` or platform keyword) and returns a converter function. The converter function takes a symbol and returns the platform specific version of that symbol.
An atom containing the platform specific predicates. Is an map of predicates,
and their platform keyword value. The predicate should take a macro &env and return a
boolean. See https://clojure.org/guides/reader_conditionals for platform keywords.
An atom containing the platform specific predicates. Is an map of predicates, and their platform keyword value. The predicate should take a macro `&env` and return a boolean. See https://clojure.org/guides/reader_conditionals for platform keywords.
(symbol env sym)Takes the target env (from &env or platform keyword), and a quoted symbol.
Transforms the symbol to platform specific symbol.
(symbol :cljs 'clojure.core.async) => cljs.core.async
Takes the target `env` (from `&env` or platform keyword), and a quoted symbol. Transforms the symbol to platform specific symbol. `(symbol :cljs 'clojure.core.async)` => `cljs.core.async`
(transform quoted-form)Transforms the symbols in a quoted form to platform specific symbols.
Takes a quoted-form to be transformed. Use this in macros.
e.g. (defmacro go [& body](env/transform (async/go ~@body)))`
WARNING: Will throw StackOverflowError for deeply nested forms.
Use io.jesi.backpack.env/symbol to transform individual symbols
Transforms the symbols in a quoted form to platform specific symbols. Takes a `quoted-form` to be transformed. Use this in macros. e.g. `(defmacro go [& body] `(env/transform (async/go ~@body)))` WARNING: Will throw StackOverflowError for deeply nested forms. Use `io.jesi.backpack.env/symbol` to transform individual symbols
(transform* env quoted-form)Transforms the symbols in a quoted form to platform specific symbols.
Takes an env (from &env or platform keyword), and a quoted-form
to be transformed.
WARNING: Will throw StackOverflowError for deeply nested forms
Use io.jesi.backpack.env/symbol to transform individual symbols
Transforms the symbols in a quoted form to platform specific symbols. Takes an `env` (from `&env` or platform keyword), and a `quoted-form` to be transformed. WARNING: Will throw StackOverflowError for deeply nested forms Use `io.jesi.backpack.env/symbol` to transform individual symbols
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 |