Showing 334 of 1,376 total issues
Function render
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
if (!this.state.currentValue || !this.state.range) {
return null;
}
Function render
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const styles = {
height: 30,
...Platform.select({
ios: {
Function render
has 45 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const min = 0.8;
const max = 3;
if (this.props.isLoading && this.props.loader) {
Function render
has 44 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<Container class={this.$props.className}>
{this.$props.title && (
<Title class={getClassName(this.$props.innerClass, 'title')}>
Function componentDidMount
has 44 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentDidMount() {
this.props.addComponent(this.internalComponent);
this.props.addComponent(this.props.componentId);
if (this.props.stream) {
Function render
has 44 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="carstore-dataset"
credentials="4HWI27QmA:58c731f7-79ab-4f55-a590-7e15c7e36721"
Function getInputEvents
has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring. Open
Open
getInputEvents({
onInput,
onBlur,
onFocus,
onKeyPress,
- 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 14 (exceeds 5 allowed). Consider refactoring. Open
Open
render() {
let markedDates = {};
const current = this.state.currentDate
? this.state.currentDate.dateString
: this.props.initialMonth || Date();
- 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 connector
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
) => component => {
const mapState = normalizeMapState(_mapState);
return {
name: `connect-${component.name}`,
Function render
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="meetup_app"
credentials="lW70IgSjr:87c5ae16-73fb-4559-a29e-0a02760d2181"
Function render
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<Slider primary style={this.props.style} className={this.props.className}>
{this.props.title && (
<Title className={getClassName(this.props.innerClass, 'title') || null}>
Function render
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="meetup_app"
credentials="lW70IgSjr:87c5ae16-73fb-4559-a29e-0a02760d2181"
Function render
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="good-books-ds"
credentials="nY6NNTZZ6:27b76b9f-18ea-456c-bc5e-3a5263ebc63d"
Function componentWillReceiveProps
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentWillReceiveProps(nextProps) {
checkPropChange(this.props.react, nextProps.react, () => this.setReact(nextProps));
checkPropChange(this.props.options, nextProps.options, () => {
const { showLoadMore, dataField } = nextProps;
const { options } = this.state;
Consider simplifying this complex logical expression. Open
Open
if (
this.state.searchAsMove !== nextState.searchAsMove
|| this.state.markerOnTop !== nextState.markerOnTop
|| this.props.showMapStyles !== nextProps.showMapStyles
|| this.props.autoCenter !== nextProps.autoCenter
Function componentWillReceiveProps
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
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 {
Function renderAsCard
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
renderAsCard({ item, triggerClickAnalytics }) {
const onData = this.$props.onData || this.$scopedSlots.onData;
const result = onData(item);
if (result) {
return (
Function render
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="meetup_app"
credentials="lW70IgSjr:87c5ae16-73fb-4559-a29e-0a02760d2181"
Function mapStateToProps
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const mapStateToProps = (state, props) => {
let options
= state.aggregations[props.componentId]
&& state.aggregations[props.componentId][props.dataField];
let range = state.aggregations[`${props.componentId}__range__internal`];
Function render
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<ReactiveBase
app="meetup_app"
credentials="lW70IgSjr:87c5ae16-73fb-4559-a29e-0a02760d2181"