Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] chore(eslint): upgrade eslint to v9 #2716

Draft
wants to merge 24 commits into
base: main
Choose a base branch
from
Draft

Conversation

liady
Copy link
Contributor

@liady liady commented Jan 20, 2025

Temporary description for reviewers:

This PR:

  • upgrades eslint to v9 and its corresponding plugins, packages and configs
  • removes individual eslint from all of our packages, except templates/skeleton
  • unifies our basic lint configuation to be in the root of the monorepo (it was empty until now)
  • fixes our lint-staged script to run on the changed files
  • removes deprecated dependencies of remix-run lint plugin and hydrogen lint plugin (not maintained)

The relevant files in the PR are:

  • eslint.config.js - this is the base eslint config for linting our codebase
  • templates/skeleton/eslint.config.js - this is the skeleton-specific configuration, and it can be removed by the skeleton users if they want.
  • the rest are (stylistic only) lint fixes

I tried to find the best subset of rules so that we will be able to have even minimal linting over our codebase, but at the same time not to flood many warnings over packages that weren't linted until now. If in the future we will want to add/enable a new rule, we can do it and fix its errors.

WHY are these changes introduced?

Fixes #0000

WHAT is this pull request doing?

HOW to test your changes?

Post-merge steps

Checklist

  • I've read the Contributing Guidelines
  • I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • I've added a changeset if this PR contains user-facing or noteworthy changes
  • I've added tests to cover my changes
  • I've added or updated the documentation

Copy link
Contributor

shopify bot commented Jan 20, 2025

Oxygen deployed a preview of your chore/eslint-upgrade branch. Details:

Storefront Status Preview link Deployment details Last update (UTC)
Skeleton (skeleton.hydrogen.shop) ✅ Successful (Logs) Preview deployment Inspect deployment January 27, 202511:19 AM
metaobjects ✅ Successful (Logs) Preview deployment Inspect deployment January 27, 202511:19 AM
custom-cart-method ✅ Successful (Logs) Preview deployment Inspect deployment January 27, 202511:19 AM
classic-remix ✅ Successful (Logs) Preview deployment Inspect deployment January 27, 202511:19 AM
third-party-queries-caching ✅ Successful (Logs) Preview deployment Inspect deployment January 27, 202511:19 AM

Learn more about Hydrogen's GitHub integration.

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.

1 participant