-
Notifications
You must be signed in to change notification settings - Fork 2
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
1 parent
761003b
commit 52d0d4d
Showing
8 changed files
with
25 additions
and
15 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
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,5 +1,15 @@ | ||
export function lengthGreaterOrEqual(str: string, minLength: number): boolean {return str.length >= minLength; } | ||
export function lengthGreater(str: string, minLength: number): boolean {return str.length > minLength; } | ||
export function lengthLowerOrEqual(str: string, maxLength: number): boolean {return str.length <= maxLength; } | ||
export function lengthLower(str: string, maxLength: number): boolean {return str.length < maxLength; } | ||
export function isRegex(str: string, regex: RegExp): boolean { return regex.test(str) }; | ||
export function lengthGreaterOrEqual(str: string, minLength: number): boolean { | ||
return str.length >= minLength; | ||
} | ||
export function lengthGreater(str: string, minLength: number): boolean { | ||
return str.length > minLength; | ||
} | ||
export function lengthLowerOrEqual(str: string, maxLength: number): boolean { | ||
return str.length <= maxLength; | ||
} | ||
export function lengthLower(str: string, maxLength: number): boolean { | ||
return str.length < maxLength; | ||
} | ||
export function isRegex(str: string, regex: RegExp): boolean { | ||
return regex.test(str); | ||
} |
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 @@ | ||
export type DecoratorFunction = () => PropertyDecorator; | ||
export type DecoratorFunction = () => PropertyDecorator; |
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 |
---|---|---|
|
@@ -146,4 +146,4 @@ export function createValidator<T extends Array<any>>( | |
constraints: [...args], | ||
}); | ||
}; | ||
}; | ||
} |
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 |
---|---|---|
|
@@ -20,4 +20,4 @@ export function Nested(expectedClass: Constructor): PropertyDecorator { | |
constraints: [], | ||
}, | ||
); | ||
}; | ||
} |
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