Skip to content

Add type-aware TypeScript ESLint rules for RN#269

Merged
kieran-osgood-shopify merged 1 commit into
mainfrom
cx-add-typescript-eslint-rules
Jun 15, 2026
Merged

Add type-aware TypeScript ESLint rules for RN#269
kieran-osgood-shopify merged 1 commit into
mainfrom
cx-add-typescript-eslint-rules

Conversation

@kieran-osgood-shopify

@kieran-osgood-shopify kieran-osgood-shopify commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

What changes are you making?

  • Move the React Native ESLint config into platforms/react-native/.eslintrc.cjs so type-aware linting resolves the workspace tsconfig.json consistently from filtered package lint scripts.
  • Enable @typescript-eslint/parser with parserOptions.project and add @typescript-eslint/require-await.
  • Keep the existing React Native lint rules for type imports, shadowing, and console usage.
  • Ignore the sample app native android/ and ios/ directories during sample ESLint runs.

How to test

  • shadowenv exec --dir . -- /opt/dev/bin/dev react-native lint module
  • shadowenv exec --dir . -- /opt/dev/bin/dev react-native lint sample

Before you merge

Important

  • I've added tests to support my implementation
  • I have read and agree with the Contribution Guidelines
  • I have read and agree with the Code of Conduct
  • I've updated the relevant platform README (platforms/swift/README.md and/or platforms/android/README.md)

Releasing a new Swift version?
  • I have bumped the version in ShopifyCheckoutKit.podspec
  • I have bumped the version in platforms/swift/Sources/ShopifyCheckoutKit/ShopifyCheckoutKit.swift
  • I have updated platforms/swift/CHANGELOG.md
  • I have updated the SwiftPM/CocoaPods version snippets in platforms/swift/README.md (major version only)
Releasing a new Android version?
  • I have bumped the versionName in platforms/android/lib/build.gradle
  • I have updated platforms/android/CHANGELOG.md
  • I have updated the Gradle/Maven version snippets in platforms/android/README.md

Tip

See the Contributing documentation for the full release process per platform.

Copy link
Copy Markdown
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions

Copy link
Copy Markdown

React Native — Coverage Report

Lines Statements Branches Functions
Coverage: 92%
91.59% (316/345) 87.25% (178/204) 100% (82/82)

@kieran-osgood-shopify kieran-osgood-shopify marked this pull request as ready for review June 10, 2026 08:58
@kieran-osgood-shopify kieran-osgood-shopify requested a review from a team as a code owner June 10, 2026 08:58

@markmur markmur left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We're using oxlint for web. Worth considering for RN too?

@kieran-osgood-shopify kieran-osgood-shopify merged commit e4a9897 into main Jun 15, 2026
21 checks passed
@kieran-osgood-shopify kieran-osgood-shopify deleted the cx-add-typescript-eslint-rules branch June 15, 2026 13:00

Copy link
Copy Markdown
Contributor Author

I'm up for consistency and oxlint seems to have much better support than the last time i tried it so at least we wont lose out too much on the ts lint rules anymore (trying to remember the issues I had last time)

Benefit is gonna be mostly unification as library code is so small that the speed difference isn't going to save more than 10 second, our lint and tsc checks only take around 12s
image.png

@markmur markmur added the #gsd:50662 Rebase Checkout Kit on UCP label Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

#gsd:50662 Rebase Checkout Kit on UCP

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants