aws-samples / aws-modernization-with-sysdig
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 53 units with 411 lines of code in units (4.3% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 5 medium size units (136 lines of code)
    • 7 small units (97 lines of code)
    • 41 very small units (178 lines of code)
0% | 0% | 33% | 23% | 43%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
js0% | 0% | 33% | 23% | 43%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
public/js0% | 0% | 33% | 23% | 43%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
jQuery()
in public/js/learn.js
33 8 1
function initLunr()
in public/js/search.js
30 2 0
30 6 2
highlight: function()
in public/js/learn.js
22 11 4
function getScrollBarWidth()
in public/js/learn.js
21 2 0
$()
in public/js/learn.js
18 4 1
renderItem: function()
in public/js/search.js
16 2 2
scrollIfAnchor: function()
in public/js/learn.js
15 5 2
function fallbackMessage()
in public/js/learn.js
14 4 1
12 1 1
jQuery()
in public/js/learn.js
11 3 1
jQuery()
in public/js/learn.js
11 4 1
$()
in public/js/hugo-learn.js
9 1 1
jQuery()
in public/js/learn.js
8 3 1
jQuery()
in public/js/learn.js
8 3 1
function search()
in public/js/search.js
7 1 1
jQuery()
in public/js/hugo-learn.js
7 1 1
function adjustForScrollbar()
in public/js/learn.js
7 2 0
var debounce = function()
in public/js/learn.js
6 3 3
delegateAnchors: function()
in public/js/learn.js
6 2 1