query
On this page

toJSON

builtins.toJSON

Primop
Docs pulled from | This Revision | 21 minutes ago

Takes 1 arguments

e


Return a string containing a JSON representation of e. Strings, integers, floats, booleans, nulls and lists are mapped to their JSON equivalents. Sets (except derivations) are represented as objects. Derivations are translated to a JSON string containing the derivation’s output path. Paths are copied to the store and represented as a JSON string of the resulting store path.

This function is not defined in a .nix file. It is likely a builtins function or an alias of a builtins function. builtins functions are predefined functions provided by Nix.

Noogle also knows

Aliases
Detected Type
toJSON :: a -> String