v2.7.0
Release Notes
This release contains several new features as well as a few performance improvements.
Schema transformations
You can now transform types, fields or arguments of an existing GraphQL
object. This gives you an easy alternative to modifying schemas. You can also implement your own custom transformers.
api
.transform(Transformer.RenameType("InnerObject" -> "Renamed"))
.transform(Transformer.ExcludeField("Query" -> "myField"))
Scala 3 union type derivation
You can now derive schemas from Scala 3 union types, and they will be translated to GraphQL unions:
type Payload = Foo | Bar
given Schema[Any, Payload] = Schema.unionType[Payload] // in GraphQL => union Payload = Foo | Bar
New features
- Added schema transformations #2218 by @ghostdogpr and @kyri-petrou
- Added derivation of
Schema
for Scala 3 union types #2215 by @oyvindberg - Added
@semanticNonNull
directive support #2180 by @XiNiHa - Added a Scala 3-specific method for building custom schemas #2211 by @kyri-petrou
Performance improvements
- Optimized random small things #2203 by @kyri-petrou
- Updated zio-prelude and optimized variable coercer #2213 by @kyri-petrou
- Removed usage of
ZIO.scoped
from APQ wrapper #2214 by @kyri-petrou - Improved
resolve
performance in Scala 2 derivation #2239 by @ghostdogpr - Optimized
Parser
#2246 by @kyri-petrou - Optimized usages of
Configurator
#2250 by @kyri-petrou
Important dependency upgrades
- Updated zio-http to 3.0.0-RC8 #2251 by @kyri-petrou