department-of-veterans-affairs/vets-website

View on GitHub

Showing 13,268 of 13,268 total issues

Function ITFBanner has 66 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const ITFBanner = props => {
  const [messageDismissed, setMessageDismissed] = useState(false);
  const [reviewInitialFocus, setReviewInitialFocus] = useState(false);

  const goHome = () => {
Severity: Major
Found in src/applications/appeals/testing/sc/components/ITFBanner.jsx - About 2 hrs to fix

    Function createDirectDepositPage has 66 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    export default function createDirectDepositPage() {
      const bankAccountProperties = {
        type: 'object',
        properties: {
          accountType: {
    Severity: Major
    Found in src/applications/edu-benefits/5490/content/directDeposit.jsx - About 2 hrs to fix

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

        render() {
          const { formConfig, buttonOnly, devOnly } = this.props;
          const devOnlyForceShowFormControls =
            environment.isLocalhost() &&
            !window.Cypress &&

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

          render() {
            const { formConfig, buttonOnly, devOnly } = this.props;
            const devOnlyForceShowFormControls =
              environment.isLocalhost() &&
              !window.Cypress &&

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

            render() {
              const { formConfig, buttonOnly, devOnly } = this.props;
              const devOnlyForceShowFormControls =
                environment.isLocalhost() &&
                !window.Cypress &&

            Function createMockAddressValidationSuccessResponse has 66 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            const createMockAddressValidationSuccessResponse = _data => {
              return {
                data: {
                  messages: [
                    {

              Function askVA has 66 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                askVA: (state = initialState, action) => {
                  switch (action.type) {
                    case SET_CATEGORY_ID:
                      return {
                        ...state,
              Severity: Major
              Found in src/applications/ask-va/reducers/index.js - About 2 hrs to fix

                Function CommunityCareProviderSelectionPage has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                export default function CommunityCareProviderSelectionPage() {
                  const pageTitle = useSelector(state => getPageTitle(state, pageKey));
                
                  const dispatch = useDispatch();
                  const { data, pageChangeInProgress, schema } = useSelector(

                  Function useUnavailableItems has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                    const useUnavailableItems = () => {
                      const { groups, items, channels } = getEntities(communicationPreferences);
                  
                      const excludedGroupIds = [
                        // Always exclude QUICK_SUBMIT and GENERAL

                    Function directDeposit has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    function directDeposit(state = initialState, action) {
                      switch (action.type) {
                        case DIRECT_DEPOSIT_FETCH_SUCCEEDED:
                        case DIRECT_DEPOSIT_SAVE_SUCCEEDED: {
                          return {
                    Severity: Major
                    Found in src/applications/personalization/profile/reducers/directDeposit.js - About 2 hrs to fix

                      Function mapStateToProps has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      const mapStateToProps = state => {
                        const { isReady: hasLoadedScheduledDowntime } = state.scheduledDowntime;
                        const isLOA3 = isLOA3Selector(state);
                        const isLOA1 = isLOA1Selector(state);
                        const isVAPatient = isVAPatientSelector(state);
                      Severity: Major
                      Found in src/applications/personalization/dashboard/components/Dashboard.jsx - About 2 hrs to fix

                        Function content has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                          const content = () => {
                            if (accessAlert) {
                              return (
                                <AccessTroubleAlertBox
                                  alertType={accessAlertTypes.VITALS}
                        Severity: Major
                        Found in src/applications/mhv-medical-records/containers/Vitals.jsx - About 2 hrs to fix

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

                            render() {
                              const contentClasses = classNames(
                                'form-expanding-group-open',
                                'wizard-content',
                                {
                          Severity: Major
                          Found in src/applications/post-911-gib-status/components/EducationWizard.jsx - About 2 hrs to fix

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

                              render() {
                                const { enrollment, id } = this.props;
                                const amendments = enrollment.amendments || [];
                                const yellowRibbonStatus = enrollment.yellowRibbonAmount > 0 && (
                                  <div className="yellow-ribbon-school">
                            Severity: Major
                            Found in src/applications/post-911-gib-status/components/EnrollmentPeriod.jsx - About 2 hrs to fix

                              File SearchMenu.jsx has 276 lines of code (exceeds 250 allowed). Consider refactoring.
                              Open

                              import PropTypes from 'prop-types';
                              import React from 'react';
                              import { connect } from 'react-redux';
                              import { toggleValues } from 'platform/site-wide/feature-toggles/selectors';
                              import FEATURE_FLAG_NAMES from 'platform/utilities/feature-toggles/featureFlagNames';
                              Severity: Minor
                              Found in src/platform/site-wide/user-nav/components/SearchMenu.jsx - About 2 hrs to fix

                                File transform.js has 276 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                import * as Sentry from '@sentry/browser';
                                import { formatDateShort } from 'platform/utilities/date';
                                import { isValid } from 'date-fns';
                                import {
                                  isStreamlinedShortForm,
                                Severity: Minor
                                Found in src/applications/financial-status-report/utils/transform.js - About 2 hrs to fix

                                  Function FormSaveErrorMessage has 65 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                  function FormSaveErrorMessage(props) {
                                    const { route, formConfig, user, form, location, showLoginModal } = props;
                                  
                                    const savedStatus = form?.savedStatus;
                                    const appType = formConfig?.customText?.appType || APP_TYPE_DEFAULT;
                                  Severity: Major
                                  Found in src/platform/forms/components/review/FormSaveErrorMessage.jsx - About 2 hrs to fix

                                    Function SubmitButtons has 65 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                    export default function SubmitButtons(props) {
                                      const { onBack, onSubmit, submission, formConfig, formErrors = {} } = props;
                                    
                                      const appType = formConfig?.customText?.appType || APP_TYPE_DEFAULT;
                                      const buttonText =
                                    Severity: Major
                                    Found in src/platform/forms-system/src/js/review/SubmitButtons.jsx - About 2 hrs to fix

                                      File index.js has 275 lines of code (exceeds 250 allowed). Consider refactoring.
                                      Open

                                      import { apiRequest } from 'platform/utilities/api';
                                      import environment from 'platform/utilities/environment';
                                      
                                      import { toSnakeCase } from '../helpers';
                                      
                                      
                                      Severity: Minor
                                      Found in src/applications/my-education-benefits/actions/index.js - About 2 hrs to fix

                                        Function createContactInformationPage has 65 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                        export default function createContactInformationPage(
                                          schema,
                                          addressField = 'veteranAddress',
                                        ) {
                                          const { homePhone, mobilePhone } = schema.properties;
                                        Severity: Major
                                        Found in src/applications/edu-benefits/pages/contactInformation.js - About 2 hrs to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language