microsoft / vscode-azureeventgrid
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 66 units with 757 lines of code in units (70.6% of code).
    • 0 very long units (0 lines of code)
    • 2 long units (168 lines of code)
    • 7 medium size units (173 lines of code)
    • 11 small units (144 lines of code)
    • 46 very small units (272 lines of code)
0% | 22% | 22% | 19% | 35%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
ts0% | 22% | 22% | 19% | 35%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src/eventSubscription/createWizard0% | 31% | 23% | 17% | 26%
src/eventSubscription/commands0% | 39% | 31% | 13% | 15%
src/eventSubscription/tree0% | 0% | 31% | 23% | 44%
src/topic/tree0% | 0% | 40% | 0% | 59%
src/topic/createWizard0% | 0% | 0% | 56% | 43%
src/utils0% | 0% | 0% | 30% | 70%
src/eventSubscription0% | 0% | 0% | 100% | 0%
src/commands0% | 0% | 0% | 0% | 100%
src0% | 0% | 0% | 0% | 100%
src/topic0% | 0% | 0% | 0% | 100%
ROOT0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
public async prompt()
in src/eventSubscription/createWizard/TopicTypeStep.ts
85 9 1
export async function createMockEventGenerator()
in src/eventSubscription/commands/mock/createMockEventGenerator.ts
83 10 2
public async execute()
in src/eventSubscription/createWizard/EventSubscriptionCreateStep.ts
42 9 1
export function getEventTypeFromTopic()
in src/eventSubscription/commands/mock/createMockEventGenerator.ts
23 9 1
export async function sendEvents()
in src/eventSubscription/commands/mock/sendEvents.ts
22 1 1
public async createChildImpl()
in src/eventSubscription/tree/EventSubscriptionProvider.ts
22 2 1
public async createChildImpl()
in src/topic/tree/TopicProvider.ts
22 2 1
async function getEndpointUrl()
in src/eventSubscription/commands/mock/sendEvents.ts
21 6 1
public async prompt()
in src/eventSubscription/createWizard/TopicListStep.ts
21 3 1
public async loadMoreChildrenImpl()
in src/eventSubscription/tree/EventSubscriptionProvider.ts
16 3 1
export async function generateEvents()
in src/eventSubscription/commands/mock/generateEvents.ts
15 4 1
15 5 3
export function registerEventSubscriptionCommands()
in src/eventSubscription/registerEventSubscriptionCommands.ts
14 1 0
public async provideCodeLenses()
in src/eventSubscription/commands/mock/MockCodeLensProvider.ts
13 1 2
private async getQuickPicks()
in src/eventSubscription/createWizard/ContainerRegistryListStep.ts
12 1 1
private async getQuickPicks()
in src/eventSubscription/createWizard/EventHubsNamespaceListStep.ts
12 1 1
private async validateName()
in src/eventSubscription/createWizard/EventSubscriptionNameStep.ts
12 4 1
private async getQuickPicks()
in src/eventSubscription/createWizard/IoTHubListStep.ts
12 1 1
private async validateName()
in src/topic/createWizard/TopicNameStep.ts
12 4 1
public async execute()
in src/topic/createWizard/TopicCreateStep.ts
11 2 1