Using Schema.Class for Nested Structures in Effect Typescript
Recursively add the class if there's a few nested schema classes
playground: https://effect.website/play/#309acb88f151
Basically I want to make
We've been using the Schema.Class as a replacement for Struct but recently been getting many cases similar to this where it simply doesn't work and isn't caught by the typesystem. Is this even a valid usecase of Schema.Class and if not could anyone advise what is the usecase of the class?
playground: https://effect.website/play/#309acb88f151
Basically I want to make
Outer with make by just passing it the correct structure and not necessarily a class instance. Is this possible? (in the real use case there are many classes and they are nested)We've been using the Schema.Class as a replacement for Struct but recently been getting many cases similar to this where it simply doesn't work and isn't caught by the typesystem. Is this even a valid usecase of Schema.Class and if not could anyone advise what is the usecase of the class?
