Showing 4,177 of 14,709 total issues
Function formReducer
has 678 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function formReducer(state = initialState, action) {
switch (action.type) {
case FORM_PAGE_OPENED: {
const { data, schema } = setupFormData(
state.data,
File form.js
has 1280 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import environment from '@department-of-veterans-affairs/platform-utilities/environment';
import React from 'react';
import { externalServices } from 'platform/monitoring/DowntimeNotification';
import {
checkboxGroupSchema,
Function LandingPage
has 655 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const LandingPage = () => {
const user = useSelector(selectUser);
const dispatch = useDispatch();
const location = useLocation();
const fullState = useSelector(state => state);
File inboxMessages.js
has 1256 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
const { sub, formatISO } = require('date-fns');
const {
senderInfo,
categoryInfo,
triageGroupNames,
File countryList.js
has 1243 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
const countryList = [
{
key: 'AFG',
label: 'Afghanistan',
value: 'AFG',
File full-example.js
has 1234 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
const all = {
resourceType: 'Bundle',
type: 'searchset',
link: [
{
File form.js
has 1230 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import { createSelector } from 'reselect';
import fullSchema5490 from 'vets-json-schema/dist/22-5490-schema.json';
import commonDefinitions from 'vets-json-schema/dist/definitions.json';
File form.js
has 1213 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import { createSelector } from 'reselect';
import { Link } from 'react-router';
import fullSchema1990e from 'vets-json-schema/dist/22-1990E-schema.json';
File VAFacilityPageV2.unit.spec.js
has 1180 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import userEvent from '@testing-library/user-event';
import { expect } from 'chai';
// eslint-disable-next-line import/no-unresolved
Function getStatusContents
has 602 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function getStatusContents(appeal, name = {}) {
const { status, aoj, programArea } = appeal.attributes;
const appealType = appeal.type;
const statusType = status.type || status;
const details = status.details || {};
File helpers.js
has 1161 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import { merge } from 'lodash';
import get from 'platform/utilities/data/get';
import omit from 'platform/utilities/data/omit';
import * as Sentry from '@sentry/browser';
File CalculateYourBenefitsForm.jsx
has 1146 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import PropTypes from 'prop-types';
import React, { useState } from 'react';
import _ from 'lodash';
import classNames from 'classnames';
File moment-tz.js
has 1126 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* istanbul ignore file */
//! moment-timezone.js
//! version : 0.5.25
//! Copyright (c) JS Foundation and other contributors
//! license : MIT
File helpers.jsx
has 1124 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* eslint-disable no-nested-ternary */
/* eslint-disable react/jsx-key */ // keys are defined, error being thrown in eslint even when key is defined
import React from 'react';
import ADDRESS_DATA from 'platform/forms/address/data';
import { v4 as uuidv4 } from 'uuid';
Function getStatusContents
has 571 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function getStatusContents(appeal, name = {}) {
const { status, aoj, programArea } = appeal.attributes;
const appealType = appeal.type;
const statusType = status.type || status;
const details = status.details || {};
Function renderAdditionalInfo
has 564 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const renderAdditionalInfo = (diaryCode, dateOfLetter, benefitType) => {
switch (diaryCode) {
case '71':
return {
status:
File helpers.js
has 1101 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import merge from 'lodash/merge';
import { format, isValid, parseISO } from 'date-fns';
import environment from '@department-of-veterans-affairs/platform-utilities/environment';
import { apiRequest } from '@department-of-veterans-affairs/platform-utilities/api';
File calculator.js
has 1093 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import { isEmpty } from 'lodash';
import { createSelector } from 'reselect';
import {
formatCurrency,
isCountryUSA,
Function FileField
has 549 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const FileField = props => {
const {
enableShortWorkflow,
errorSchema,
formContext,
Function FacilitiesMap
has 545 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const FacilitiesMap = props => {
const [map, setMap] = useState(null);
const searchResultTitleRef = useRef(null);
const searchResultMessageRef = useRef();
const [isMobile, setIsMobile] = useState(window.innerWidth <= 481);