Showing 34 of 108 total issues
Function render
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
return (
<div className="presets">
<div className="jumbotron header">
<div className="container">
Function render
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
var action;
if (this.props.action) {
action = (
<td style={{width: '123px'}}>
Function render
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
return (
<div className="layouts margin-fix">
<div className="jumbotron header">
<div className="container">
Function render
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
var legend = [
['layout', 'duplicate', 'Layout'],
['other', 'question-sign', 'Other'],
['ability', 'font', 'Ability'],
Function onload
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
window.onload = function () {
ReactDOM.render((
<ReactRouter.Router>
<ReactRouter.Redirect from="/" to="home"/>
<ReactRouter.Route path="/" component={Layout}>
Function render
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
var lastAppVersion = localStorage.lastAppVersion || '1.9.2';
var lastEngineVersion = localStorage.lastEngineVersion || '1.8.2';
var engineChanges = this.renderCategory(changelog.engine, lastEngineVersion);
var appChanges = this.renderCategory(changelog.app, lastAppVersion);
Function render
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
var span = this.props.width.toString().replace(/\./g, '-');
if (this.props.name === 'empty') {
return (<div className={"key key-empty span-" + span}> <br/> </div>);
} else {
Function render
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function () {
var sets = [];
for (var i = 0; i < this.props.sets.length; i++) {
sets.push(
<Setting
Avoid too many return
statements within this function. Open
Open
return 0;
Avoid too many return
statements within this function. Open
Open
return matcher[c[1]];
Avoid too many return
statements within this function. Open
Open
return ['key-open', shortMatch[c[1]], 'Open ' + window.capitalize(c[1])];
Avoid too many return
statements within this function. Open
Open
return ['key-open', c[1], 'Open ' + window.capitalize(c[1])];
Function compareVersion
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Open
window.compareVersion = function (a, b) {
if (!a) return -1;
if (!b) return 1;
var _a = a.split('.');
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function render
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Open
render: function () {
var span = this.props.width.toString().replace(/\./g, '-');
if (this.props.name === 'empty') {
return (<div className={"key key-empty span-" + span}> <br/> </div>);
} else {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"