TypstDocumentation

Types

To style your document, you need to work with values of different kinds: Lengths specifying the size of your elements, colors for your text and shapes, and more. Typst categorizes these into clearly defined types and tells you where it expects which type of value.

Apart from very basic types for numeric values and typical types known from programming languages, Typst provides a special type for content. A value of this type can hold anything that you can enter into your document: Text, elements like headings and shapes, and style information.

In some places of Typst more specialized data types are used. Instead of listing all of them here, they are explained where they are relevant.

Types