Handling Readonly Properties After Schema Decoding in Effect Typescript
After doing a
But doesn't that make it super inconvenient to use the parsed values?
Example:
This will not compile, because
How do we deal with that? Surely there is a more elegant solution than having to add "readonly" to all our function types, isn't there?
https://effect.website/play/#74820cdde077
Schema.decodeUnknown, all the properties are readonly.But doesn't that make it super inconvenient to use the parsed values?
Example:
This will not compile, because
len takes a mutable array as input, but is getting a readonly.How do we deal with that? Surely there is a more elegant solution than having to add "readonly" to all our function types, isn't there?
https://effect.website/play/#74820cdde077
