dart-lang / dump-info-visualizer
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 74 units with 871 lines of code in units (54.2% of code).
    • 0 very long units (0 lines of code)
    • 3 long units (203 lines of code)
    • 5 medium size units (137 lines of code)
    • 18 small units (255 lines of code)
    • 48 very small units (276 lines of code)
0% | 23% | 15% | 29% | 31%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
dart0% | 23% | 15% | 29% | 31%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
lib/src0% | 18% | 14% | 31% | 35%
web0% | 56% | 23% | 11% | 8%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
void _addMetadata()
in lib/src/hierarchy_view.dart
81 19 5
void init()
in web/viewer.dart
64 6 0
void _renderRow()
in lib/src/hierarchy_view.dart
58 9 2
List diff()
in lib/src/diff_alg.dart
33 10 2
void sort()
in lib/src/tree_table.dart
27 13 1
void _display()
in lib/src/hierarchy_view.dart
26 6 0
void _switchSlide()
in web/viewer.dart
26 3 2
void _setupProgramwideInfo()
in lib/src/program_info_view.dart
25 4 0
factory HistoryState()
in lib/src/history_state.dart
18 6 2
void show()
in lib/src/logical_row.dart
18 4 1
void ready()
in lib/src/drag_drop_view.dart
17 1 0
TableCellElement _cell()
in lib/src/hierarchy_view.dart
16 3 4
void clear()
in lib/src/tree_table.dart
16 3 0
Set _triviallyReachedFrom()
in lib/src/info_helper.dart
16 5 1
TableRowElement _generateRow()
in lib/src/dependency_view.dart
16 2 2
void ready()
in lib/src/diff_view.dart
15 1 0
static HistoryState fromJson()
in lib/src/history_state.dart
14 5 1
int _computeSize()
in lib/src/hierarchy_view.dart
13 5 3
void columnInfo()
in lib/src/tree_table.dart
13 3 3
void traverseNames()
in lib/src/info_helper.dart
13 3 2