Using a Schema with a Service in a Factory That Expects `R` to Be `never`

hi, i have a schema const MaskEmailFromStringSchema: Schema.Schema<string, string, MaskingService> and i want to use this in a schema which expects R to be never

Factory({
  // it expects R to be never
  schema: Schema.Struct({ 
    email: MaskEmailFromStringSchema // how do i provide service directly here? 
  })
})


and i want to provide service directly in the schema without encoding/decoding, how can i do this?
Was this page helpful?