Plum lets you create UML class diagrams in Typst; inspired by but not compatible with PlantUML.
To add this package to your project, use this:
#import "@preview/plum:0.0.1": *
#let expr = "2 * (2 + x)"
#eval(mode: "math", expr)
#plum.parse(expr)
#plum.eval(expr, x: 3)
See the manual for details.