-
Notifications
You must be signed in to change notification settings - Fork 5
Feature: Upgrade ts-extractor #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
029b793 to
70c78d2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Non functional changes requested.
| const referenceTuples = GetApiItemReferences(extractedData, [[apiItem.Name, apiItem.ApiItems]]); | ||
| list = list.concat(referenceTuples); | ||
|
|
||
| const referencesList = GetApiItemReferences(extractedData, [{ Alias: apiItem.Name, Ids: apiItem.ApiItems }]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move to separate const just like in line 144.
| itemsReference: Contracts.ApiItemReferenceTuple | ||
| itemsReference: Contracts.ApiItemReference[] | ||
| ): ApiItemReference[] { | ||
| let list: ApiItemReference[] = []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider changing variable list name to overallReferences.
| return apiItems; | ||
| } | ||
|
|
||
| export function LogWithApiItemPosition(logLevel: LogLevel, apiItem: Contracts.ApiItemDto, message: string): void { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe default value for logLevel would be handy?
export function LogWithApiItemPosition(apiItem: Contracts.ApiItemDto, message: string, logLevel: LogLevel = LogLevel.Warning): void(default value can be other than LogLevel.Warning)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not really sure if it's right decision. Because default Log function for logging is:
Log: (level: LogLevel, ...messages: any[]) => number;
No description provided.