Showing 545 of 2,098 total issues
Avoid too many return
statements within this function. Open
Open
return [
`transform: translateX(${SLIDE_SIZES[size]}%);`,
'transform: none;',
];
Avoid too many return
statements within this function. Open
Open
return [
`transform: translateY(${SLIDE_SIZES[size]}%);`,
'transform: none;',
];
Avoid too many return
statements within this function. Open
Open
return ['transform: rotateY(0);', 'transform: rotateY(90deg);'];
Avoid too many return
statements within this function. Open
Open
return undefined;
Avoid too many return
statements within this function. Open
Open
return `border: ${value};`;
Avoid too many return
statements within this function. Open
Open
return [`transform: rotate(0deg);`, `transform: rotate(-359deg);`];
Avoid too many return
statements within this function. Open
Open
return [];
Avoid too many return
statements within this function. Open
Open
if (chartProp) return [chartProp];
Avoid too many return
statements within this function. Open
Open
return [uniqueValues, undefined];
Avoid too many return
statements within this function. Open
Open
return option[Object.keys(option)[0]];
Avoid too many return
statements within this function. Open
Open
return option;
Avoid too many return
statements within this function. Open
Open
return undefined;
Avoid too many return
statements within this function. Open
Open
return [undefined, [min, max]];
Avoid too many return
statements within this function. Open
Open
return undefined;
Avoid too many return
statements within this function. Open
Open
return valuesX.every((_, i) =>
valuesX[i].value.every((value, index) => value === valuesY[i].value[index]),
);
Avoid too many return
statements within this function. Open
Open
return undefined; // pre-default, no kind
Avoid too many return
statements within this function. Open
Open
return undefined;
Avoid too many return
statements within this function. Open
Open
return controlsMenuItems.push(item);
Avoid too many return
statements within this function. Open
Open
return input;
Function ControlledDataTable
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Open
export const ControlledDataTable = () => {
const [checked, setChecked] = React.useState([]);
const onCheck = (event, value) => {
if (event.target.checked) {
- 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"