department-of-veterans-affairs/vets-website

View on GitHub

Showing 4,231 of 14,884 total issues

Function renderCalendar has 72 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  const renderCalendar = () => {
    if (!displayedInputs.calendar) return null;

    const dependentDropdowns = (
      <div>
Severity: Major
Found in src/applications/gi/components/profile/CalculateYourBenefitsForm.jsx - About 2 hrs to fix

    File VAPServiceProfileField.jsx has 286 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    import React from 'react';
    import PropTypes from 'prop-types';
    import { connect } from 'react-redux';
    import { focusElement } from 'platform/utilities/ui';
    
    

      File supportingDocuments.js has 286 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      import React from 'react';
      import { titleUI } from 'platform/forms-system/src/js/web-component-patterns';
      import { useFeatureToggle } from 'platform/utilities/feature-toggles';
      
      export const childAttendsCollege = child => child.attendingCollege;

        Function OverviewPage has 71 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        const OverviewPage = () => {
          const title = 'Your VA debt and bills';
          useHeaderPageTitle(title);
        
          useEffect(() => {

          Function renderLocationInputField has 71 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            const renderLocationInputField = () => {
              const {
                locationChanged,
                searchString,
                geolocationInProgress,
          Severity: Major
          Found in src/applications/facility-locator/components/SearchControls.jsx - About 2 hrs to fix

            File EvidenceVaRecords.jsx has 285 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            import React, { useState, useEffect } from 'react';
            import { VaTextInput } from '@department-of-veterans-affairs/component-library/dist/react-bindings';
            
            import { EVIDENCE_VA_PATH } from '../constants';
            import { content } from '../content/evidenceVaRecords';
            Severity: Minor
            Found in src/applications/appeals/testing/sc/components/EvidenceVaRecords.jsx - About 2 hrs to fix

              Function render has 71 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                render() {
                  const { form } = this.props;
                  const { submission, data } = form;
                  const submitDate = submission.timestamp;
                  const { veteranFullName: fullName } = data;
              Severity: Major
              Found in src/applications/edu-benefits/10282/containers/ConfirmationPage.jsx - About 2 hrs to fix

                Function getPreviouslyVerified has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                  const getPreviouslyVerified = () => {
                    let enrollments = [];
                    const combinedEnrollmentsObj = combineEnrollmentsWithStartMonthDGIB(
                      sortedEnrollmentsDGIB(enrollmentVerifications),
                    );

                  Function BuildPage has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  export const BuildPage = props => {
                    const { title, field, id, goToPath, subTitle } = props;
                  
                    const headerRef = useRef(null);
                  
                  

                    Function FacilityConfirmation has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    const FacilityConfirmation = props => {
                      const { data, goBack, goForward, goToPath } = props;
                      const selectedFacility = data['view:plannedClinic'].veteranSelected;
                      const selectedCaregiverSupportFacility =
                        data['view:plannedClinic'].caregiverSupport;

                      Function FacilityCheckboxGroup has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      const FacilityCheckboxGroup = props => {
                        const {
                          facilityName,
                          multipleFacilities,
                          triageTeams,

                        File CalendarWidget.jsx has 285 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        /**
                         * Shared calendar widget component used by the VAOS application.
                         * @module components/calendar
                         */
                        import React, { useState } from 'react';
                        Severity: Minor
                        Found in src/applications/vaos/components/calendar/CalendarWidget.jsx - About 2 hrs to fix

                          Function CCRequest has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          export default function CCRequest() {
                            const pageTitle = useSelector(state => getPageTitle(state, pageKey));
                          
                            const { data, pageChangeInProgress } = useSelector(
                              state => getFormPageInfo(state, pageKey),

                            Function claimDetailReducer has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            export default function claimDetailReducer(state = initialState, action) {
                              switch (action.type) {
                                case RESET_UPLOADS: {
                                  return initialState;
                                }
                            Severity: Major
                            Found in src/applications/claims-status/reducers/uploads.js - About 2 hrs to fix

                              Function FirstFAQSection has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                              export const FirstFAQSection = () => {
                                return (
                                  <>
                                    <h3 className="dhp-faq-section-header">DHP Fitbit Pilot</h3>
                                    <va-accordion
                              Severity: Major
                              Found in src/applications/dhp-connected-devices/components/FAQSections.jsx - About 2 hrs to fix

                                File address.js has 284 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                import { createSelector } from 'reselect';
                                import set from '../../utilities/data/set';
                                import get from '../../utilities/data/get';
                                import unset from '../../utilities/data/unset';
                                import { validateWhiteSpace } from '../validations';
                                Severity: Minor
                                Found in src/platform/forms/definitions/address.js - About 2 hrs to fix

                                  File ChapterSectionCollection.jsx has 284 lines of code (exceeds 250 allowed). Consider refactoring.
                                  Open

                                  import React from 'react';
                                  import { PropTypes } from 'prop-types';
                                  import { isReactComponent } from '~/platform/utilities/ui';
                                  import {
                                    createPageListByChapter,

                                    File ContestableIssuesWidget.jsx has 284 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    import React, { useEffect, useState } from 'react';
                                    import PropTypes from 'prop-types';
                                    import { connect } from 'react-redux';
                                    import { Link } from 'react-router';
                                    import { VaModal } from '@department-of-veterans-affairs/component-library/dist/react-bindings';

                                      File EnhancedSpouseEmploymentRecord.jsx has 284 lines of code (exceeds 250 allowed). Consider refactoring.
                                      Open

                                      import React, { useState } from 'react';
                                      import { connect } from 'react-redux';
                                      import PropTypes from 'prop-types';
                                      import { setData } from 'platform/forms-system/src/js/actions';
                                      import {

                                        File EnhancedEmploymentRecord.jsx has 284 lines of code (exceeds 250 allowed). Consider refactoring.
                                        Open

                                        import React, { useState } from 'react';
                                        import { connect } from 'react-redux';
                                        import PropTypes from 'prop-types';
                                        import { setData } from 'platform/forms-system/src/js/actions';
                                        import {
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language