All syntax guides
Short, practical guides on programming syntax, language fundamentals, and the tools developers reach for every day.
3,965 guides across 14 topics
Topics
Popular guides
Most readLatest guides
Page 42 of 397Python Jinja2 Custom Filters and Macros
Learn how to create custom filters and macros in Python Jinja2 templates. Includes syntax, practical examples, macro imports, and guidance on when to use each.
Python Jinja2 Templates: Variables, Loops, and Conditions
Learn how Jinja2 variables, for loops, and if conditions work in Python templates, including filters, undefined-variable handling, whitespace control, and performance tips.
Parsing Nested XML and Attributes with Python xmltodict
Learn how to use xmltodict to parse nested XML into dictionaries, read attributes with the @ prefix, handle repeated elements and namespaces, and write XML back out.
Convert XML to Dictionary and Back with Python xmltodict
Learn how to use Python's xmltodict to convert XML to dictionaries and back, including attribute handling, namespaces, round-trip limitations, and when to prefer ElementTree.
Python msgpack vs JSON: Choosing a Serialization Format
python msgpack vs json: Compare Python msgpack and JSON for serialization: data types, performance, compatibility, and practical guidance for choosing the right format.
Python msgpack: Serialize and Deserialize Python Objects
Learn how to use the Python msgpack library to serialize and deserialize objects: core API, type mapping, custom classes, limitations, and safety.
Python orjson vs json performance: API differences
Compare Python's standard json module with orjson: API differences, type support, and performance tradeoffs that matter in production.
Python orjson: Serializing Dataclasses with datetime, numpy, and pydantic
python orjson datetime dataclass numpy and pydantic: Learn how to serialize Python dataclasses with datetime and numpy types using orjson, and how pydantic models fit...
Python orjson: dumps, loads, and serialization options
Use Python's orjson library for fast JSON serialization. Learn orjson.dumps and orjson.loads options, dataclass support, datetime and UUID handling, and key differences from the standard json module.
python prettytable vs tabulate: Which to Use?
Compare Python prettytable and tabulate for formatting tabular data: API style, customization, output formats, performance, and when to choose each.