From 7b302771439a536620ea53c36a47c54e950f4605 Mon Sep 17 00:00:00 2001 From: Rene Saarsoo Date: Fri, 25 Dec 2020 19:55:25 +0200 Subject: [PATCH] Export also ValidationError & combined exception union --- src/index.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index 29a8742..cd660ed 100644 --- a/src/index.ts +++ b/src/index.ts @@ -8,8 +8,11 @@ export { Workout, Interval, Comment } from "./ast"; export { Duration } from "./Duration"; export { Intensity, ConstantIntensity, RangeIntensity, FreeIntensity } from "./Intensity"; export { ZoneType, intensityValueToZoneType } from "./ZoneType"; -export { ParseError } from "./parser/ParseError"; export { SourceLocation } from "./parser/tokenizer"; +import { ParseError } from "./parser/ParseError"; +import { ValidationError } from "./parser/ValidationError"; +export type ZwiftoutException = ParseError | ValidationError; +export { ParseError, ValidationError }; // utils export { totalDuration } from "./stats/totalDuration";