Skip to content

Commit 40231a0

Browse files
authored
Merge pull request #29 from qmonmert/refacto
fix: 🐛 (parser) rename validtor in validator
2 parents 1578f1f + d5e656c commit 40231a0

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ ng-parsel offers the following configurations.
9797
| parseDirectives | true | If set to `true` ng-parsel will parse Angular Directives and include them in the output. |
9898
| parseModules | true | If set to true ng-parsel will parse Angular Modules and include them in the output. |
9999
| parseHarnesses | true | If set to true ng-parsel will parse Harness test files (all files ending with `.harness.ts`) and include them in the output. |
100-
| parseValidators | true | If set to true ng-parsel will parse Validators (all files ending with `.validtor.ts`) and include them in the output. |
100+
| parseValidators | true | If set to true ng-parsel will parse Validators (all files ending with `.validator.ts`) and include them in the output. |
101101
| parseSpecs | true | If set to true ng-parsel will parse testing files (all files ending with `.spec.ts`) and include them in the output. |
102102
| singleFile | true | If set to to `true` the output will be written to a `ng-parsel.json` file in the output directory. If set to false, ng-parsel will generate multiple output files, one for each `componentType`. (Find out more on component types in the [next section](#component-type)) |
103103

src/parser/parser.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import { NgParselSpec } from './spec/spec.model.js';
2121
import { NgParselPipe } from './pipe/pipe.model.js';
2222
import { parseHarnesses } from './harness/harness.parser.js';
2323
import { parseValidator } from './validator/validator.parser.js';
24-
import { NgParselValidtor } from './validator/validator.model.js';
24+
import { NgParselValidator } from './validator/validator.model.js';
2525
import { NgParselService } from './services/service.model.js';
2626
import { parseService } from './services/service.parser.js';
2727

@@ -30,7 +30,7 @@ export function parse(configuration: NgParselConfig): void {
3030

3131
let ngParselComponents: NgParselComponent[] = [],
3232
ngParselSpecs: NgParselSpec[] = [],
33-
ngParselValidators: NgParselValidtor[] = [],
33+
ngParselValidators: NgParselValidator[] = [],
3434
ngParselHarnesses: NgParselHarness[] = [],
3535
ngParselPipes: NgParselPipe[] = [],
3636
ngParselModules: NgParselModule[] = [],
@@ -114,7 +114,7 @@ function writeOutputFiles(
114114
ngParselSpecs: NgParselSpec[],
115115
ngParselHarnesses: NgParselHarness[],
116116
ngParselPipes: NgParselPipe[],
117-
ngParselValidators: NgParselValidtor[]
117+
ngParselValidators: NgParselValidator[]
118118
): void {
119119
if (!existsSync(config.out as string)) {
120120
mkdirSync(config.out as string, { recursive: true });
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { NgParselOutput } from '../shared/model/types.model.js';
22
import { NgParselMethod } from '../shared/model/method.model.js';
33

4-
export interface NgParselValidtor extends NgParselOutput {
4+
export interface NgParselValidator extends NgParselOutput {
55
methodsPublicExplicit: NgParselMethod[];
66
}

src/parser/validator/validator.parser.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import { parseClassName } from '../shared/parser/class.parser.js';
44
import { NgParselOutputType } from '../shared/model/types.model.js';
55
import { parseExplicitPublicMethods } from '../shared/parser/method.parser.js';
66

7-
import { NgParselValidtor } from './validator.model.js';
7+
import { NgParselValidator } from './validator.model.js';
88

9-
export function parseValidator(ast: ts.SourceFile, validatorFilePath: string): NgParselValidtor {
9+
export function parseValidator(ast: ts.SourceFile, validatorFilePath: string): NgParselValidator {
1010
return {
1111
className: parseClassName(ast),
1212
filePath: validatorFilePath,

0 commit comments

Comments
 (0)