awslabs / aws-sdk-api-changes
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 669 units with 9,870 lines of code in units (84.9% of code).
    • 3 very long units (1,165 lines of code)
    • 20 long units (1,316 lines of code)
    • 100 medium size units (3,068 lines of code)
    • 158 small units (2,296 lines of code)
    • 388 very small units (2,025 lines of code)
11% | 13% | 31% | 23% | 20%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
js13% | 13% | 31% | 22% | 19%
py0% | 7% | 26% | 32% | 34%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
assets/js13% | 13% | 31% | 22% | 19%
apichanges0% | 7% | 22% | 34% | 35%
tools0% | 0% | 100% | 0% | 0%
ROOT0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
942 106 2
function processAttrs()
in assets/js/vue.js
118 30 1
105 26 1
function hydrate()
in assets/js/vue.js
81 32 4
80 15 1
function _createElement()
in assets/js/vue.js
79 27 5
function enter()
in assets/js/vue.js
77 32 2
start: function start()
in assets/js/vue.js
72 19 5
render: function render()
in assets/js/vue.js
70 26 1
68 23 2
function addHandler()
in assets/js/vue.js
68 22 8
function parseFilters()
in assets/js/vue.js
66 38 1
def process()
in apichanges/repo.py
66 19 3
chars: function chars()
in assets/js/vue.js
65 26 3
function updateChildren()
in assets/js/vue.js
64 19 5
function patchVnode()
in assets/js/vue.js
63 31 6
function createComponent()
in assets/js/vue.js
62 13 5
function genData$2()
in assets/js/vue.js
61 21 2
59 16 2
function createElm()
in assets/js/vue.js
55 13 7