Showing 334 of 1,376 total issues
Function render
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="airbeds-test-app"
credentials="X8RsOu0Lp:9b4fe1a4-58c6-4089-a042-505d86d9da30"
Function render
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function render
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="airbeds-test-app"
credentials="X8RsOu0Lp:9b4fe1a4-58c6-4089-a042-505d86d9da30"
Function componentWillReceiveProps
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
checkSomePropChange(this.props, nextProps, ['dataField', 'nestedField'], () => {
this.updateQuery(this.state.currentDistance, nextProps);
Function render
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function componentWillReceiveProps
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
let startDate = null;
let endDate = null;
- 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 getButtonProps
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
getButtonProps({ onClick, onKeyDown, onKeyUp, onBlur }) {
return {
click: event => {
this.setState({
isOpen: true,
- 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 componentWillReceiveProps
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => {
this.setReact(nextProps);
});
- 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 componentWillReceiveProps
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
if (!isEqual(this.props.defaultSelected, nextProps.defaultSelected)) {
this.handleDateChange(nextProps.defaultSelected, false, nextProps);
} 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"
Further reading
Function componentWillReceiveProps
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
checkSomePropChange(this.props, nextProps, ['showHistogram', 'interval'], () =>
this.updateQueryOptions(nextProps),
);
Function render
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function componentWillReceiveProps
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkSomePropChange(
this.props,
nextProps,
['highlight', 'dataField', 'highlightField'],
Function render
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function componentWillReceiveProps
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
checkSomePropChange(this.props, nextProps, ['showHistogram', 'interval'], () =>
this.updateQueryOptions(nextProps),
);
Function render
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
if (this.$scopedSlots.default) {
return this.$scopedSlots.default(this.$props);
}
const filtersToRender = this.renderFilters();
Function render
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
if (!this.state.isReady) {
return <Text>Loading...</Text>;
}
Function renderFilters
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
renderFilters() {
const { selectedValues } = this;
return Object.keys(selectedValues)
.filter(
id => this.components.includes(id) && selectedValues[id].showFilter
Function render
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function booksCard
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
booksCard(data) {
return {
title: (
<div
className="book-title-card text-center"
Function render
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
return (
<Container style={this.props.style} className={this.props.className}>
{this.props.title && (
<Title className={getClassName(this.props.innerClass, 'title') || null}>