Skip to content

Conversation

@redreceipt
Copy link
Member

No description provided.

@redreceipt redreceipt marked this pull request as ready for review December 11, 2025 14:21
@redreceipt redreceipt requested a review from Copilot December 11, 2025 14:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds ESLint configuration and enforcement to the web-shared package, bringing it in line with consistent code styling standards across the project. The changes include adding a linting script, configuring ESLint rules, and applying automated formatting fixes throughout the codebase.

Key Changes:

  • Added ESLint configuration file (.eslintrc.js) with rules for import ordering, comment formatting, and code style
  • Added lint script to package.json for the web-shared package
  • Updated GitHub Actions workflow to include linting checks for the web-shared package alongside web-embeds
  • Applied automated formatting fixes across 100+ files including import statement reorganization, comment spacing corrections, and code formatting improvements

Reviewed changes

Copilot reviewed 166 out of 168 changed files in this pull request and generated 28 comments.

Show a summary per file
File Description
.github/workflows/lint.yml Extended CI workflow to run lint checks on web-shared package; updated to use latest GitHub Actions versions
packages/web-shared/.eslintrc.js New ESLint configuration defining import ordering, comment formatting, and style rules
packages/web-shared/package.json Added lint script to enable ESLint checks
yarn.lock Updated dependency entries for string-width, strip-ansi, and wrap-ansi packages
packages/web-shared/**/*.js Applied automated formatting fixes including import reordering, comment spacing, quote consistency, and line break adjustments across all JavaScript files

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

import SearchStyles from '../Searchbar/Search.styles';

import { useCurrentChurch } from '../../hooks';
import { Box, Avatar } from '../../ui-kit';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import Avatar.

Suggested change
import { Box, Avatar } from '../../ui-kit';
import { Box } from '../../ui-kit';

Copilot uses AI. Check for mistakes.
import { useCurrentChurch } from '../../hooks';
import { Box, Avatar } from '../../ui-kit';
import ProfileButton from '../Profile/ProfileButton';
import SearchStyles from '../Searchbar/Search.styles';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import SearchStyles.

Suggested change
import SearchStyles from '../Searchbar/Search.styles';

Copilot uses AI. Check for mistakes.
import { withTheme } from 'styled-components';
import styled, { css } from 'styled-components';
import { themeGet } from '@styled-system/theme-get';
import styled, { withTheme, css } from 'styled-components';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import css.

Suggested change
import styled, { withTheme, css } from 'styled-components';
import styled, { withTheme } from 'styled-components';

Copilot uses AI. Check for mistakes.
H6,
SmallBodyText,
} from '../../../ui-kit';
import { Avatar, Card, Box, Button, Input, H2, H5, H6, SmallBodyText } from '../../../ui-kit';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused imports H2, H5.

Suggested change
import { Avatar, Card, Box, Button, Input, H2, H5, H6, SmallBodyText } from '../../../ui-kit';
import { Avatar, Card, Box, Button, Input, H6, SmallBodyText } from '../../../ui-kit';

Copilot uses AI. Check for mistakes.
import { getURLFromType } from '../utils';
import { ContentCard, Box, H3, systemPropTypes, Button } from '../ui-kit';
import { useNavigation } from '../providers/NavigationProvider';
import { ContentCard, Box, H3, systemPropTypes, Button } from '../ui-kit';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import H3.

Suggested change
import { ContentCard, Box, H3, systemPropTypes, Button } from '../ui-kit';
import { ContentCard, Box, systemPropTypes, Button } from '../ui-kit';

Copilot uses AI. Check for mistakes.

import { Check } from '@phosphor-icons/react';
import { unit } from '../../utils';
import isNil from 'lodash/isNil';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import isNil.

Copilot uses AI. Check for mistakes.
import { Title, Image, BottomSlot, CompleteIndicator, Ellipsis } from './MediaItem.styles';
import LiveChip from './LiveChip';
import { useLivestreamStatus } from '../../hooks';
import { Title, Image, BottomSlot, CompleteIndicator, Ellipsis } from './MediaItem.styles';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused imports Image, Title.

Copilot uses AI. Check for mistakes.
import { useLivestreamStatus } from '../../hooks';
import { Title, Image, BottomSlot, CompleteIndicator, Ellipsis } from './MediaItem.styles';
import { useVideoMediaProgress, useLivestreamStatus } from '../../hooks';
import { BodyText, SmallBodyText, Box, H4, systemPropTypes, ProgressBar } from '../../ui-kit';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused imports BodyText, SmallBodyText.

Copilot uses AI. Check for mistakes.
import { withTheme } from 'styled-components';
import styled, { css } from 'styled-components';
import { themeGet } from '@styled-system/theme-get';
import styled, { withTheme, css } from 'styled-components';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import css.

Copilot uses AI. Check for mistakes.
import { withTheme } from 'styled-components';
import styled, { css } from 'styled-components';
import { themeGet } from '@styled-system/theme-get';
import styled, { withTheme, css } from 'styled-components';
Copy link

Copilot AI Dec 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import css.

Copilot uses AI. Check for mistakes.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@redreceipt
Copy link
Member Author

@vitlelis i'll address unused import warnings in a follow up

Copy link

@dsilva609 dsilva609 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm this looks like the old eslint config (<8.57) format. Can we update this to be eslint 9 compatible as outlined here? https://eslint.org/docs/latest/use/migrate-to-9.0.0

@redreceipt
Copy link
Member Author

Hmm this looks like the old eslint config (<8.57) format. Can we update this to be eslint 9 compatible as outlined here? https://eslint.org/docs/latest/use/migrate-to-9.0.0

can we do that in a follow up? the purpose of this PR is simply to introduce lint checks to the majority of the code. I've already found and fixed one bug.

@dsilva609
Copy link

Hmm this looks like the old eslint config (<8.57) format. Can we update this to be eslint 9 compatible as outlined here? https://eslint.org/docs/latest/use/migrate-to-9.0.0

can we do that in a follow up? the purpose of this PR is simply to introduce lint checks to the majority of the code. I've already found and fixed one bug.

Actually, since this is in maintenance mode, we can probably leave it as is 👍

@redreceipt redreceipt requested a review from dsilva609 December 11, 2025 15:26
@redreceipt redreceipt added this pull request to the merge queue Dec 11, 2025
Merged via the queue into main with commit 3c9a940 Dec 11, 2025
3 checks passed
@redreceipt redreceipt deleted the lint-web-shared branch December 11, 2025 15:33
Copy link
Contributor

@nlewis84 nlewis84 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm good with this since we are pushing everyone to get off this package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants