Skip to content

Commit

Permalink
Merge branch 'v3.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
samchon committed Sep 10, 2022
2 parents 493a670 + a8ff16f commit cc898ab
Show file tree
Hide file tree
Showing 62 changed files with 3,936 additions and 300 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,10 @@ Tag Kind | Target Type
`@range (number, number]` | number
`@minimum {number}` | number
`@maximum {number}` | number
`@exclusiveMinimum {number}` | number
`@exclusiveMaximum {number}` | number
`@multipleOf {number}` | number
`@step {number}` | number
`@length {number} \| [number, number)` | string
`@minLength {number}` | string
`@maxLength {number}` | string
Expand Down Expand Up @@ -311,6 +315,26 @@ export interface TagExample {
*/
range: number;

/**
* Step tag requires minmum or exclusiveMinimum tag.
*
* 3, 13, 23, 33, ...
*
* @step 10
* @exclusiveMinimum 3
* @range [3
*/
step: number;

/**
* Value must be multiple of the given number.
*
* -5, 0, 5, 10, 15, ...
*
* @multipleOf 5
*/
multipleOf: number;

/* -----------------------------------------------------------
STRINGS
----------------------------------------------------------- */
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "typescript-json",
"version": "3.2.1",
"version": "3.2.2",
"description": "Runtime type checkers and 5x faster JSON.stringify() function",
"main": "lib/index.js",
"typings": "lib/index.d.ts",
Expand All @@ -15,7 +15,7 @@
"prettier": "prettier --write ./**/*.ts",
"test": "node test",
"test:manual": "node test/manual",
"test:application:replace": "npm run build:test && node test/features/application/replace && npm run prettier"
"test:application:replace": "node test/features/application/replace && npm run prettier"
},
"repository": {
"type": "git",
Expand Down
1 change: 1 addition & 0 deletions src/factories/MetadataCollection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export class MetadataCollection {
type.symbol.getDocumentationComment(checker),
)) ||
undefined,
jsDocTags: type.symbol?.getJsDocTags() || [],
validated: false,
index: this.index_++,
recursive: false,
Expand Down
1 change: 1 addition & 0 deletions src/factories/MetadataFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,7 @@ export namespace MetadataFactory {
prop.getJsDocTags(),
),
);
property.jsDocTags.push(...prop.getJsDocTags());
}
return obj;
}
Expand Down
Loading

0 comments on commit cc898ab

Please sign in to comment.