microsoft / typescript-styled-plugin
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 53 units with 616 lines of code in units (89.5% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 1 medium complex units (41 lines of code)
    • 3 simple units (56 lines of code)
    • 49 very simple units (519 lines of code)
0% | 0% | 6% | 9% | 84%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
ts0% | 0% | 6% | 9% | 84%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src0% | 0% | 6% | 9% | 84%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
function translateCompletionItemKind()
in src/_language-service.ts
41 19 2
private getCompletionItems()
in src/_language-service.ts
31 7 2
public updateFromPluginConfig()
in src/_configuration.ts
12 6 1
public getCached()
in src/_language-service.ts
13 6 2
private translateDiagnostic()
in src/_language-service.ts
26 5 5
private translateHover()
in src/_language-service.ts
29 5 3
private translateCodeActions()
in src/_language-service.ts
19 5 2
function translateSeverity()
in src/_language-service.ts
15 5 2
16 5 3
function isAfter()
in src/_language-service.ts
6 3 2
private translateOutliningSpan()
in src/_language-service.ts
18 3 2
function toDisplayParts()
in src/_language-service.ts
11 3 1
26 3 2
function arePositionsEqual()
in src/_language-service.ts
6 2 2
function overlaps()
in src/_language-service.ts
6 2 2
private get cssLanguageService()
in src/_language-service.ts
7 2 0
private get scssLanguageService()
in src/_language-service.ts
7 2 0
public getCompletionEntryDetails()
in src/_language-service.ts
18 2 3
public getQuickInfoAtPosition()
in src/_language-service.ts
12 2 2
public getOutliningSpans()
in src/_language-service.ts
15 2 1