Showing 2,372 of 6,033 total issues
File ExtraOptions.tsx
has 606 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
File drillby.test.ts
has 602 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
File DashboardBuilder.tsx
has 601 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
Function dbReducer
has 259 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function dbReducer(
state: Partial<DatabaseObject> | null,
action: DBReducerActionType,
): Partial<DatabaseObject> | null {
const trimmedState = {
Function DndMetricSelect
has 256 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const DndMetricSelect = (props: any) => {
const { onChange, multi, datasource, savedMetrics } = props;
const extra = useMemo<{ disallow_adhoc_metrics?: boolean }>(() => {
let extra = {};
File index.tsx
has 593 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
Function transformProps
has 255 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function transformProps(
chartProps: EchartsGaugeChartProps,
): GaugeChartTransformedProps {
const {
width,
File index.tsx
has 584 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
Function exploreReducer
has 249 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function exploreReducer(state = {}, action) {
const actionHandlers = {
[DYNAMIC_PLUGIN_CONTROLS_READY]() {
return {
...state,
Function transformProps
has 249 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const transformProps = (
chartProps: TableChartProps,
): TableChartTransformedProps => {
const {
height,
Function DateFilterLabel
has 249 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function DateFilterLabel(props: DateFilterControlProps) {
const {
onChange,
onOpenPopover = noOp,
onClosePopover = noOp,
Function Rose
has a Cognitive Complexity of 63 (exceeds 5 allowed). Consider refactoring. Open
Open
function Rose(element, props) {
const {
data,
width,
height,
- 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
File RightMenu.tsx
has 579 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
File FiltersConfigModal.tsx
has 578 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
File Select.tsx
has 577 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
Function transformProps
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function transformProps(
chartProps: EchartsBoxPlotChartProps,
): BoxPlotChartTransformedProps {
const {
width,
File index.tsx
has 574 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
Function AdhocFilterEditPopoverSimpleTabContent
has 244 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const AdhocFilterEditPopoverSimpleTabContent: FC<Props> = props => {
const {
onSubjectChange,
onOperatorChange,
isOperatorRelevant,
File series.ts
has 573 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* eslint-disable no-underscore-dangle */
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
File Rose.js
has 570 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file