Resolve Duplicate Property Signature in Schema without Transformation

how to achieve this in schema w/o transformation?
const _Rarity = S.Struct({
  name: S.String,
  color: ColorSchema,
});
S.Struct({
  rarity: _Rarity.pipe(S.pluck("name")),
  color: S.propertySignature(_Rarity.pipe(S.pluck("color"))).pipe(S.fromKey("rarity")),
})

I get an error
error: Uncaught (in promise) Error: Duplicate property signature
Was this page helpful?