Tag

Tag

Declarative struct tag parser for Go

Tag

Tag is a lightweight Go library for parsing raw struct tag strings into strongly typed Go values.

Go's reflect.StructTag gives you tag values as strings. That is fine for small cases, but real projects usually need more: default values, boolean flags, lists, maps, nested options, custom types, and consistent error handling. Tag centralizes that work behind a small declarative schema.

Where To Start

Start with Introduction for the big picture, Quickstart for a working parser, or jump into Guides when you need a specific tag shape.

On this page