Skip to content

Release v5.1.0

Choose a tag to compare

@github-actions github-actions released this 06 Jul 19:05
Immutable release. Only release title and notes can be modified.
✨ [feat] Add opt-in TypeScript union wrapping

✨ [feat] Add multilineTypeUnionsWrapThreshold as a default-off Prettier option that wraps TSUnionType members only when the configured member threshold is exceeded.

✨ [feat] Route TypeScript union nodes through a dedicated printer helper before the existing multiline array rewriting, preserving existing array behavior and Prettier defaults when the option is disabled.

🧪 [test] Cover option validation, default one-line union formatting, threshold equality, configured multiline unions, and generic type-argument unions across the shared TypeScript fixtures.

📝 [docs] Document the new union threshold option and clarify that comment overrides remain array-only.