Use cattrs.preconf for specialized serialization formats
mainThe cattrs.preconf package provides pre-configured converters for various serialization formats. Instead of manually configuring a cattrs.Converter to work with specific libraries, you can use these submodules to get a converter that is already optimized and configured for the target format (e.g., JSON, YAML, TOML, Msgpack, etc.).
Available submodules include:
cattrs.preconf.bson(BSON)cattrs.preconf.cbor2(CBOR)cattrs.preconf.json(Standard JSON)cattrs.preconf.msgpack(MessagePack)cattrs.preconf.msgspec(msgspec)cattrs.preconf.orjson(orjson)cattrs.preconf.pyyaml(PyYAML)cattrs.preconf.tomlkit(TOMLKit)cattrs.preconf.tomllib(Standard TOML)cattrs.preconf.ujson(ujson)