Showing 4,231 of 14,884 total issues
Function answerReviewLabel
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const answerReviewLabel = (key, formValues) => {
const answer = formValues[key];
const dischargeMonth =
monthLabelMap[formValues[SHORT_NAME_MAP.DISCHARGE_MONTH]] || '';
Function ClaimantContactInformation
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function ClaimantContactInformation(props) {
const formikContext = useFormikContext();
return (
<>
Function additionalBenefits
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export default function additionalBenefits(schema, options) {
// Use the defaults as necessary, but override with the options given
const mergedOptions = { ...defaults, ...options };
const { fields, required } = mergedOptions;
Function mapEnrollmentVerificationsForSubmission
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const mapEnrollmentVerificationsForSubmission = ev => {
// The enrollments are in order with the most recent first. Look
// for the first non-null verificationStatus (or, the most recent
// month) that was verified as either correct or incorrect.
const mostRecentVerifiedEnrollmentIndex = ev.enrollmentVerifications.findIndex(
Function componentDidUpdate
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentDidUpdate(prevProps) {
const {
fieldName,
forceEditView,
successCallback,
Function fetchRatedDisabilities
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function fetchRatedDisabilities() {
return async dispatch => {
const response = await getData(
'/disability_compensation_form/rated_disabilities',
);
Function PrefillAlerts
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const PrefillAlerts = () => {
return (
<>
<h1 className="vads-u-margin-bottom--8">Alerts</h1>
Function componentDidUpdate
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentDidUpdate(prevProps) {
const {
fieldName,
forceEditView,
successCallback,
Function componentDidUpdate
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentDidUpdate(prevProps) {
const {
fieldName,
forceEditView,
successCallback,
Function BackButton
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const BackButton = props => {
const { action, prevUrl, router, text = null } = props;
const {
getCurrentPageFromRouter,
getPreviousPageFromRouter,
Function createRoutesWithStore
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const createRoutesWithStore = () => {
return (
<Switch>
{routes.map((route, i) => {
const options = {
Function ActionLink
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const ActionLink = props => {
const { action, appointmentId, app, startTime } = props;
const { t } = useTranslation();
const { getPreCheckinComplete } = useStorage(app);
Function ViewPaymentsApp
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function ViewPaymentsApp(props) {
const headerRef = useCallback(node => {
node?.focus();
}, []);
Function RogersStem
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const RogersStem = () => {
useEffect(() => {
recordEvent({
event: 'howToWizard-alert-displayed',
'reason-for-alert': 'help with STEM program debt',
Function renderAddressOption
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const renderAddressOption = (address, id = 'userEntered') => {
const hasConfirmedSuggestions = apiData.length > 0;
const { addressStreet, cityStateZip, addressCountry } = formatAddress(
address,
);
Function OtherExpensesInputList
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const OtherExpensesInputList = props => {
const { errorSchema, formContext } = props;
const errorList = errorSchema?.otherExpenses?.__errors;
const { submitted } = formContext;
Function setUnsavedNavigationError
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
typeOfError => {
if (typeOfError === null) {
setNavigationError(null);
}
if (
Function runAdvancedSearch
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
) => async (dispatch, getState) => {
dispatch({ type: Actions.Search.START });
const isPilot = getIsPilotFromState(getState);
try {
const response = await searchFolderAdvanced(
Function letterItems
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const letterItems = (this.props.letters || []).map((letter, index) => {
let content;
let letterTitle;
let helpText;
if (letter.letterType === LETTER_TYPES.benefitSummary) {
Function searchReducer
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const searchReducer = (state = initialState, action) => {
switch (action.type) {
case Actions.Search.RUN_ADVANCED:
return {
...state,