Showing 4,231 of 14,884 total issues
Function updateSchemaFromUiSchema
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export function updateSchemaFromUiSchema(
schema,
uiSchema,
formData,
index = 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 AreaOfDisagreement
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const AreaOfDisagreement = ({
data = {},
pagePerItemIndex,
goBack,
goForward,
- 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 ApplicantRelationshipPage
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export default function ApplicantRelationshipPage({
data,
genOp,
setFormData,
goBack,
- 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 SearchResultsHeader
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export const SearchResultsHeader = props => {
const { searchResults, pagination, query } = props;
const {
inProgress,
context,
- 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 BDDPage
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const BDDPage = ({ setPageState, state = '' }) => {
const [ariaDescribedby, setAriaDescribedby] = useState('');
const [isDirty, setIsDirty] = useState(false);
const [errorMessage, setErrorMessage] = useState(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 transformForSubmit
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export default function transformForSubmit(formConfig, form) {
const transformedData = JSON.parse(
sharedTransformForSubmit(formConfig, form),
);
const { preparerType, otherReasons } = transformedData;
- 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 PrimaryAddressWithAutofill
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const PrimaryAddressWithAutofill = props => {
const { formContext, formData, idSchema, onChange, schema } = props;
const { reviewMode, submitted } = formContext;
const { properties: schemaProps } = schema;
const { veteranAddress } = useSelector(state => state.form.data);
- 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 BankruptcyDetails
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const BankruptcyDetails = ({
data,
goBack,
goForward,
setFormData,
- 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 ContactInfo
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const ContactInfo = ({
data,
goBack,
goForward,
onReviewPage,
- 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 SearchBenefits
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
const SearchBenefits = ({
cumulativeService,
dispatchShowModal,
eligForPostGiBill,
enlistmentService,
- 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 KeywordSearch
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
export function KeywordSearch({
className,
inputValue,
label,
labelAdditional,
- 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 ToeApp.jsx
has 288 lines of code (exceeds 250 allowed). Consider refactoring. Open
import React, { useEffect, useState } from 'react';
import { connect } from 'react-redux';
import { isArray } from 'lodash';
import PropTypes from 'prop-types';
import { VaBreadcrumbs } from '@department-of-veterans-affairs/web-components/react-bindings';
File pdfAddress.js
has 288 lines of code (exceeds 250 allowed). Consider refactoring. Open
// pdf-address.js
// customized version of src/platform/forms/definitions/address.js,
// with support added for PDF-specific maxLengths [street, street2, & city].
import { createSelector } from 'reselect';
import {
File householdIncomeChapter.js
has 287 lines of code (exceeds 250 allowed). Consider refactoring. Open
import {
benefits,
additionalIncomeValues,
spouseBenefits,
spouseBenefitRecords,
Function expandAllEnrollments
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
const expandAllEnrollments = () => {
/*
make sure the begin date and end date are in the same month,
if not then expand the enrollment period for each month
between the begin and end dates of the enrollment
Function DeactivatedMHVIds
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
const DeactivatedMHVIds = () => {
const content = {
heading: 'Your My HealtheVet account is inactive',
alertText: (
<div>
Function DependencyVerificationModal
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
const DependencyVerificationModal = props => {
const nodeToWatch = document.getElementsByTagName('body')[0];
const [otherModal, setOtherModal] = useState(null);
const openModal = () => {
Function Wrapper
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
const Wrapper = props => {
const {
children,
pageTitle,
titleOverride,
Function Appeals
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
const Appeals = () => {
useEffect(() => {
recordEvent({
event: 'howToWizard-alert-displayed',
'reason-for-alert':
Function render
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
const crumbs = [
{
href: `../status`,
label: 'Status details',