v2.35.0
Overview
Moved this release as it was incorrectly tagged as v2.34.3.
Improved Error Messaging for Form Pointers
Pointer panic messages now explicitly include “Form” where applicable, making debugging clearer and resolving #892.
Expanded String Format Support
Added support for duration and idn-hostname string formats, improving schema expressiveness and validation coverage.
Header Parsing Fix
Fixed several subtle issues in header detection that occurred when output fields were slices, arrays, or maps, which could cause headers (notably []*http.Cookie) to be incorrectly applied or documented. The parsing logic now correctly inspects the root type of collection fields and adds support for hidden headers, allowing them to be excluded from generated OpenAPI documentation. These changes resolve multiple long-standing documentation and serialization bugs without introducing new behavior.
What's Changed
- fix: include “Form” in pointer panic message (fixes #892) by @wolveix in #938
- feat: support duration and IDN-hostname string formats by @wolveix in #939
- docs: add simple HTML docs by @wolveix in #941
- fix: header parsing by @wolveix in #944
- perf(schema): optimize convertType with fast paths for compatible types by @baagod in #931
- Added exhaustive error code wrappers by @rhodeon in #876
New Contributors
Full Changelog: https://github.com/danielgtaylor/huma/compare/v2.34.2...v2.34.3