microsoft / ObjectStoreProvider
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 77 units with 1,321 lines of code in units (40.1% of code).
    • 2 very long units (480 lines of code)
    • 0 long units (0 lines of code)
    • 14 medium size units (383 lines of code)
    • 14 small units (220 lines of code)
    • 47 very small units (238 lines of code)
36% | 0% | 28% | 16% | 18%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
ts36% | 0% | 28% | 16% | 18%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src37% | 0% | 30% | 17% | 14%
src/ordered-map0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
objectStores: join()
in src/IndexedDbProvider.ts
251 44 2
async open()
in src/IndexedDbProvider.ts
229 47 4
private _checkNextTransactions()
in src/TransactionLockHelper.ts
43 10 0
transactionFailed()
in src/TransactionLockHelper.ts
33 3 2
static iterateOverCursorRequest()
in src/IndexedDbProvider.ts
32 5 2
export function serializeKeyToString()
in src/ObjectStoreProviderUtils.ts
32 4 2
export function openListOfProviders()
in src/ObjectStoreProvider.ts
30 3 5
transactionComplete()
in src/TransactionLockHelper.ts
29 3 1
private _getKeyCountForRange()
in src/InMemoryProvider.ts
28 11 4
private _getKeyValues()
in src/InMemoryProvider.ts
25 7 4
private _getKeysForRange()
in src/InMemoryProvider.ts
24 9 4
private _resolveCursorResult()
in src/IndexedDbProvider.ts
22 3 3
private _cleanTransaction()
in src/TransactionLockHelper.ts
22 4 1
public put()
in src/InMemoryProvider.ts
21 5 2
private _getKeyRangeForRange()
in src/IndexedDbProvider.ts
21 3 4
export function formListOfKeys()
in src/ObjectStoreProviderUtils.ts
21 4 2
private _removeFromIndices()
in src/InMemoryProvider.ts
20 3 3
public internal_getKeysFromItem()
in src/InMemoryProvider.ts
19 6 1
export function serializeValueToOrderableString()
in src/ObjectStoreProviderUtils.ts
19 5 1
objectStores: join()
in src/IndexedDbProvider.ts
17 2 2