| 1 |
import type {ErrorObject} from "../../types" |
| 2 |
|
| 3 |
export enum DiscrError { |
| 4 |
Tag = "tag", |
| 5 |
Mapping = "mapping", |
| 6 |
} |
| 7 |
|
| 8 |
export type DiscrErrorObj<E extends DiscrError> = ErrorObject< |
| 9 |
"discriminator", |
| 10 |
{error: E; tag: string; tagValue: unknown}, |
| 11 |
string |
| 12 |
> |