Showing 4,231 of 14,884 total issues
Function IntroductionPage
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const IntroductionPage = props => {
const { route, router } = props;
const startForm = useCallback(
() => {
Function formatAddress
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function formatAddress(address) {
/* eslint-disable prefer-template */
const {
country,
postalCode,
Function VetTec
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const VetTec = () => {
useEffect(() => {
recordEvent({
event: 'howToWizard-alert-displayed',
'reason-for-alert': 'help with VET TEC program debt',
Function sendMessage
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const sendMessage = (message, attachments) => async dispatch => {
try {
await createMessage(message, attachments);
dispatch(
addAlert(
Function LandingPageAuth
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const LandingPageAuth = () => {
const dispatch = useDispatch();
const fullState = useSelector(state => state);
const inbox = useSelector(state => state.sm.folders?.folder);
const [prefLink, setPrefLink] = useState('');
Function sortMessages
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
data => {
return data.sort((a, b) => {
if (
[SENT_DATE_DESCENDING.value, DRAFT_DATE_DESCENDING.value].includes(
sortOrder,
Function fetchRequestDetails
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function fetchRequestDetails(id) {
return async (dispatch, getState) => {
try {
const state = getState();
let request = selectAppointmentById(state, id, [
Function recipientsReducer
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const recipientsReducer = (state = initialState, action) => {
switch (action.type) {
case Actions.AllRecipients.GET_LIST: {
const {
associatedTriageGroups,
Function openFacilityPage
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function openFacilityPage() {
return async (dispatch, getState) => {
try {
const initialState = getState();
const newBooking = selectCovid19VaccineNewBooking(initialState);
Function updateFacilitySortMethod
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function updateFacilitySortMethod(sortMethod, uiSchema) {
return async (dispatch, getState) => {
let location = null;
const { facilities } = selectCovid19VaccineNewBooking(getState());
const calculatedDistanceFromCurrentLocation = facilities.some(
Function getPageContent
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getPageContent() {
const { claim } = this.props;
// Return null if the claim/ claim.attributes dont exist
if (!claimAvailable(claim)) {
Function mapStateToProps
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function mapStateToProps(state) {
const claimsState = state.disability.status;
const claimsV2Root = claimsState.claimsV2; // this is where all the meat is for v2
const services = getBackendServices(state);
Function render
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const { events, missingEvents } = this.props;
const { expanded } = this.state;
let pastEventsList = [];
if (events.length) {
Function RatingsAbout
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const RatingsAbout = () => {
return (
<div className="vads-u-padding-top--4 about-ratings">
<div className="mobile-lg:vads-u-font-size--h3 vads-u-padding-bottom--1p5 vads-u-font-weight--bold vads-u-font-family--serif small-screen-font">
About ratings
Function render
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
if (isEmpty(this.props.calculated)) {
return (
<VaLoadingIndicator
data-testid="loading-indicator"
Function renderViewButtons
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const renderViewButtons = () => {
if (totalRowCount > DEFAULT_ROWS_VIEWABLE) {
if (viewableRowCount !== totalRowCount) {
const remainingRowCount = totalRowCount - viewableRowCount;
const showNextCount =
Function CollapsibleList
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const CollapsibleList = () => {
return (
<div id="SupportingFiles-collapsiblePanel">
<div className="input-section">
<div
Function generateRows
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const generateRows = signInServiceName => {
const { link, label: buttonText } =
SERVICE_PROVIDERS[signInServiceName] || {};
return [
{
Function ViewDependentsList
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function ViewDependentsList(props) {
let mainContent;
const manageDependentsToggle = props?.manageDependentsToggle ?? null;
if (props.loading) {
mainContent = (
Function LabsAndTestsListItem
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const LabsAndTestsListItem = props => {
const { record } = props;
return (
<va-card