relayjs / relay-devtools
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 228 units with 3,801 lines of code in units (41.1% of code).
    • 0 very complex units (0 lines of code)
    • 2 complex units (198 lines of code)
    • 9 medium complex units (613 lines of code)
    • 12 simple units (506 lines of code)
    • 205 very simple units (2,484 lines of code)
0% | 5% | 16% | 13% | 65%
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
js0% | 5% | 16% | 13% | 65%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/devtools/views0% | 9% | 20% | 21% | 48%
packages/relay-devtools-core/src0% | 0% | 20% | 5% | 73%
src/devtools0% | 0% | 43% | 0% | 56%
src/backend/util0% | 0% | 13% | 0% | 86%
shells/browser/shared0% | 0% | 0% | 20% | 79%
src0% | 0% | 0% | 0% | 100%
shells/dev/relay-app0% | 0% | 0% | 0% | 100%
src/backend0% | 0% | 0% | 0% | 100%
shells/dev/src0% | 0% | 0% | 0% | 100%
shells0% | 0% | 0% | 0% | 100%
ROOT0% | 0% | 0% | 0% | 100%
packages/relay-devtools0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
139 30 5
59 28 1
131 25 7
33 19 3
179 15 3
36 14 2
36 14 2
79 14 7
50 13 3
29 13 1
40 11 2
100 10 6
128 9 5
26 9 2
26 9 2
28 9 1
24 8 0
47 8 2
19 7 2
13 7 3
47 6 0
14 6 0
34 6 4
17 5 1
35 5 1
19 5 1
27 5 1
58 5 4
16 5 2
19 5 2
39 5 3
9 5 1
36 5 1
35 5 4
19 5 2
14 5 4
13 5 2
17 4 0
10 4 1
20 4 1
10 4 1
12 4 1
20 4 0
12 4 2
8 4 0
14 4 0
12 4 0
9 4 1
12 4 0
12 4 1