microsoft / PowerBI-visuals-StrippetsBrowser
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 285 units with 3,200 lines of code in units (24.7% of code).
    • 1 very complex units (142 lines of code)
    • 1 complex units (172 lines of code)
    • 7 medium complex units (373 lines of code)
    • 21 simple units (503 lines of code)
    • 255 very simple units (2,010 lines of code)
4% | 5% | 11% | 15% | 62%
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
ts24% | 0% | 19% | 34% | 21%
js0% | 6% | 9% | 11% | 71%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src24% | 0% | 19% | 34% | 21%
lib/@uncharted/strippets/src0% | 11% | 5% | 12% | 70%
lib/@uncharted/thumbnails/src0% | 0% | 17% | 12% | 69%
lib/@uncharted/strippets.common/src0% | 0% | 9% | 4% | 85%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public static converter()
in src/StrippetsVisual.ts
142 52 5
FeatureContent.prototype.renderEntities = function()
in lib/@uncharted/strippets/src/strippets.outline.feature.js
172 40 1
Readerview.prototype.placeReader = function()
in lib/@uncharted/thumbnails/src/thumbnails.readerview.js
79 20 2
private onLoadArticle()
in src/StrippetsVisual.ts
70 14 1
util.getCSSRule = function()
in lib/@uncharted/strippets.common/src/uncharted.util.js
29 13 1
Outline.prototype.registerEvents = function()
in lib/@uncharted/strippets/src/strippets.outline.js
54 13 0
Thumbnail.prototype._loadImages = function()
in lib/@uncharted/thumbnails/src/thumbnails.thumbnail.js
60 12 2
Outline.prototype.constructLayout = function()
in lib/@uncharted/strippets/src/strippets.outline.js
36 11 1
constructor()
in src/StrippetsVisual.ts
45 11 1
bucket: getBucket()
in src/StrippetsVisual.ts
60 10 1
Strippets.prototype.filter = function()
in lib/@uncharted/strippets/src/strippets.js
22 9 2
Outline.prototype.getTransitionSizes = function()
in lib/@uncharted/strippets/src/strippets.outline.js
25 9 1
Thumbnail.prototype._init = function()
in lib/@uncharted/thumbnails/src/thumbnails.thumbnail.js
21 9 1
27 9 4
Reader.prototype.getActualReaderWidth = function()
in lib/@uncharted/strippets/src/strippets.outline.reader.js
22 8 2
public static sanitizeHTML()
in src/StrippetsVisual.ts
24 8 2
var onContainerMouseMove = function()
in lib/@uncharted/strippets.common/src/uncharted.scrollable.js
14 7 1
Strippets.prototype.mapEntitiesToIconMap = function()
in lib/@uncharted/strippets/src/strippets.js
25 7 2
IBindable.prototype.off = function()
in lib/@uncharted/thumbnails/src/IBindable.js
26 7 2
module.exports.mapEntitiesToIconMap = function()
in lib/@uncharted/thumbnails/src/thumbnails.util.js
25 7 2