Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
export declare class YoniusError { | ||
constructor(message: string, code?: number) | ||
isClient(): boolean | ||
isServer(): boolean | ||
} | ||
|
||
export declare class OperationalError extends YoniusError { | ||
constructor(message?: string, code?: number) | ||
} | ||
|
||
export declare class NotFoundError extends OperationalError {} | ||
|
||
export declare class NotImplementedError extends OperationalError {} | ||
|
||
export declare class ValidationError extends OperationalError {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
export * from "./error"; | ||
export * from "./main"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
export declare function eq<T>( | ||
valueC: T, | ||
message?: string | ||
): (value?: T, ctx?: any) => boolean; | ||
|
||
export declare function gt<T>( | ||
valueC: T, | ||
message?: string | ||
): (value?: T, ctx?: any) => boolean; | ||
|
||
export declare function notEmpty( | ||
message?: string | ||
): (value?: string | unknown[], ctx?: any) => boolean; | ||
|
||
export declare function isIn<T>( | ||
valueC: T[], | ||
message?: string | ||
): (value?: T, ctx?: any) => boolean; | ||
|
||
export declare function isSimple( | ||
message?: string | ||
): (value?: string, ctx?: any) => boolean; | ||
|
||
export declare function isEmail( | ||
message?: string | ||
): (value?: string, ctx?: any) => boolean; | ||
|
||
export declare function isUrl( | ||
message?: string | ||
): (value?: string, ctx?: any) => boolean; | ||
|
||
export declare function isRegex( | ||
regex: string, | ||
message?: string | ||
): (value?: string, ctx?: any) => boolean; |