Enhancing `ApiError` Type with `_tag` Property in TypeScript Using `effect/schema`
I'm using the
However, I would also like to add a
How do I accomplish this? I tried simply adding this to the
effect/schema package to parse an ApiError response from my backend. I have defined the following:However, I would also like to add a
_tag: 'ApiError' property to the resulting POJO object of type ApiError allowing it to be matched with other errors on _tag:How do I accomplish this? I tried simply adding this to the
ApiError, but then I get a compile error on ApiErrorSchema.