Showing 222 of 243 total issues
File ConnectionConfigurationApi.ts
has 487 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* tslint:disable */
/* eslint-disable */
/**
* Aigonix.Bridge.M3
* Bridge API - made for Aigonix Studio
File AigonIsLostSvg.tsx
has 422 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Copyright (c) Aigonix. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
import React from 'react';
File MessageMappingApi.ts
has 412 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* tslint:disable */
/* eslint-disable */
/**
* Aigonix.Bridge.M3
* Bridge API - made for Aigonix Studio
Function webpack
has 176 lines of code (exceeds 75 allowed). Consider refactoring. Open
function webpack(env: Args, argv: Args) {
const isProduction = argv.mode === 'production';
const port = process.env.port || argv.port || defaultPort;
const tenantId = env.tenantId || argv.tenantId || defaultTenantId; //Can be overridden by passing --env tenantId=xxx
const userId = env.userId || argv.userId || defaultUserId; //Can be overridden by passing --env userId=xxx
File index.js
has 362 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Copyright (c) Aigonix. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
const { Router } = require('express');
Function Graph
has 166 lines of code (exceeds 75 allowed). Consider refactoring. Open
export const Graph = (props: GraphProps) => {
const [spec, vegaRef, setParams] = useThemedSpec(
{
width: 'container',
height: 'container',
File CommandMappingApi.ts
has 350 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* tslint:disable */
/* eslint-disable */
/**
* Aigonix.Bridge.M3
* Bridge API - made for Aigonix Studio
Function M3SetupForm
has a Cognitive Complexity of 29 (exceeds 5 allowed). Consider refactoring. Open
export const M3SetupForm = React.forwardRef<M3SetupFormRef, M3SetupFormProps>((
{
connectionId,
connection,
hasSelectedDeploymentType,
- 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 FileUploadForm
has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring. Open
export const FileUploadForm = React.forwardRef<FileUploadFormRef, FileUploadFormProps>(function FileUploadForm({
onSelected, onConfirmed, allowMultipleFiles = false, hideDropArea = false, validFileExtensions = [] }:
FileUploadFormProps, ref: React.ForwardedRef<FileUploadFormRef>) {
const [dragActive, setDragActive] = useState(false);
- 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 RealtimeSyncSection
has 146 lines of code (exceeds 75 allowed). Consider refactoring. Open
export const RealtimeSyncSection = () => {
const { enqueueSnackbar } = useSnackbar();
const connectionId = useConnectionIdFromRoute();
const { data: webhookStatus, isLoading } = useConnectionsIdWebhookStatusGet(
Function useLogFilters
has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring. Open
export const useLogFilters = (
initialFilters: LogFilterObject,
availableMicroservices: LogFilterMicroservice[],
availableEnvironments: string[],
): [LogFilterObject, React.Dispatch<React.SetStateAction<LogFilterObject>>] => {
- 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 CustomIcons.tsx
has 313 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Copyright (c) Aigonix. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
import React from 'react';
Function SetupContainer
has 137 lines of code (exceeds 75 allowed). Consider refactoring. Open
export const SetupContainer = () => {
const navigate = useNavigate();
const connectionId = useConnectionIdFromRoute();
const formRef = useRef<M3SetupFormRef>(null);
const fileUploadRef = useRef<FileUploadFormRef>(null);
File api.ts
has 310 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Copyright (c) Aigonix. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
import { MicroserviceSimple } from './index';
ConnectionConfigurationApi
has 28 functions (exceeds 20 allowed). Consider refactoring. Open
export class ConnectionConfigurationApi extends runtime.BaseAPI {
/**
* GET basic authentication configuration for the connection, if present
*/
Function ConfigurationFilesIndex
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
export const ConfigurationFilesIndex = ({ applicationId, currentMicroservice }: ConfigurationFilesIndexProps) => {
const fileUploadRef = useRef<FileUploadFormRef>(null);
const { enqueueSnackbar } = useSnackbar();
const [configFileTableRows, setConfigFileTableRows] = useState<ConfigFilesTableRow[]>([]);
- 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 parseQuery
has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring. Open
const parseQuery = (query) => {
const parsed = {
labels: [],
pipeline: [],
};
- 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 DataGrid
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export const DataGrid = ({ applicationId, microservice, rows, setRows, selectedRowIds, onSelectRowIds, rowMode, onRowChange, onRowUpdate }: DataGridProps) => {
const { enqueueSnackbar } = useSnackbar();
const [restartInfoBoxIsOpen, setRestartInfoBoxIsOpen] = useState(false);
- 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 AigonFixingSvg.tsx
has 276 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Copyright (c) Aigonix. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
import React from 'react';
Function LogPanel
has 113 lines of code (exceeds 75 allowed). Consider refactoring. Open
export const LogPanel = (props: LogPanelProps) => {
const [showTimestamp, setShowTimestamp] = useState(false);
const [showMicroservice, setShowMicroservice] = useState(false);
const [logContextDialog, setLogContextDialog] = useState<LogContextDialogState>({