Transit functions for the on-the-wire EDN communication to common remotes. Includes support for Fulcro tempids, and can be extended to support additional application-specific data types.
Transit functions for the on-the-wire EDN communication to common remotes. Includes support for Fulcro tempids, and can be extended to support additional application-specific data types.
(reader in)
(reader in opts)
(reader)
(reader opts)
Create a transit reader.
opts
: (optional) options to pass to cognitect.transit/reader
(such as data type handlers).Create a transit reader. - `opts`: (optional) options to pass to `cognitect.transit/reader` (such as data type handlers).
(serializable? v)
Checks to see that the value in question can be serialized by the default fulcro writer by actually attempting to serialize it. This is not an efficient check.
Checks to see that the value in question can be serialized by the default fulcro writer by actually attempting to serialize it. This is *not* an efficient check.
(transit-clj->str data)
(transit-clj->str data opts)
Use transit to encode clj data as a string. Useful for encoding initial app state from server-side rendering.
data
: Arbitrary dataopts
: (optional) Options to send when creating a writer
. Always preserves metadata.WARNING: metadata encoding will not work in CLJS if you don't use the latest transit-js. If using shadow-cljs, this means placing that in your package.json file (not relying on the jar version).
Use transit to encode clj data as a string. Useful for encoding initial app state from server-side rendering. - `data`: Arbitrary data - `opts`: (optional) Options to send when creating a `writer`. Always preserves metadata. WARNING: metadata encoding will not work in CLJS if you don't use the latest transit-js. If using shadow-cljs, this means placing that in your package.json file (not relying on the jar version).
(transit-str->clj str)
(transit-str->clj str opts)
Use transit to decode a string into a clj data structure. Useful for decoding initial app state when starting from a server-side rendering.
Use transit to decode a string into a clj data structure. Useful for decoding initial app state when starting from a server-side rendering.
(writer out)
(writer out opts)
Create a transit writer.
out
: An acceptable output for transit writers.opts
: (optional) options to pass to cognitect.transit/writer
(such as data type handlers).Create a transit writer. - `out`: An acceptable output for transit writers. - `opts`: (optional) options to pass to `cognitect.transit/writer` (such as data type handlers).
(writer)
(writer opts)
Create a transit writer.
out
: An acceptable output for transit writers.opts
: (optional) options to pass to cognitect.transit/writer
(such as handlers).Create a transit writer. - `out`: An acceptable output for transit writers. - `opts`: (optional) options to pass to `cognitect.transit/writer` (such as handlers).
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close