Skip to content

chore: enable Snap TypeScript checking - #237

Open
ulissesferreira wants to merge 1 commit into
mainfrom
chore/enable-snap-typescript-check
Open

chore: enable Snap TypeScript checking#237
ulissesferreira wants to merge 1 commit into
mainfrom
chore/enable-snap-typescript-check

Conversation

@ulissesferreira

@ulissesferreira ulissesferreira commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Explanation

The repository had TypeScript configuration files for the packages, but the package source was not being type-checked as part of the normal CI lint workflow. Snap builds were transpiled by mm-snap, so TypeScript diagnostics could be missed until later in development.

This pull request makes TypeScript checking an explicit CI requirement for all repository and workspace packages:

  • Fixes existing TypeScript problems that are now visible
  • Adds lint:tsc script
  • Adds lint:tsc to the CI checks
  • Standardizes Snap package's tsconfig.json files so they all match
  • Root tsconfig files are now made with Snap packages as first class! The "normal" library package is the exception so it gets its own tsconfig overrides

References

None.

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

@ulissesferreira
ulissesferreira requested review from a team as code owners August 28, 2026 15:23
@ulissesferreira
ulissesferreira deployed to default-branch August 28, 2026 15:23 — with GitHub Actions Active
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from 41895cc to eee95b6 Compare August 31, 2026 11:04
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch 3 times, most recently from 32bd0b7 to 39671c5 Compare September 1, 2026 10:42
Comment thread packages/stellar-wallet-snap/src/config.ts Outdated
Comment thread packages/stellar-wallet-snap/tsconfig.json Outdated
Comment thread packages/bitcoin-wallet-snap/tsconfig.json Outdated
Comment thread packages/tron-wallet-snap/tsconfig.json Outdated
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch 4 times, most recently from cf3cbe8 to af54615 Compare September 1, 2026 14:00
@@ -1,7 +1,14 @@
{
"extends": "../../tsconfig.packages.build.json",

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This package is the only exception so let's not have that root file

Comment thread tsconfig.packages.json Outdated
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from af54615 to a829c64 Compare September 1, 2026 14:43
@socket-security

socket-security Bot commented Sep 1, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcomment-json@​4.5.1 ⏵ 4.6.2100 +1100100 +185100

View full report

@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch 4 times, most recently from 9a2c92f to 7e42b45 Compare September 2, 2026 10:54
Comment thread packages/solana-wallet-snap/src/core/validation/structs.ts
Comment thread packages/bitcoin-wallet-snap/src/handlers/validation.ts
Comment thread packages/stellar-wallet-snap/src/config.ts Outdated
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from 7e42b45 to 252b66a Compare September 2, 2026 11:10

@taran-a taran-a 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.

@ulissesferreira, GG—nice work. I spotted one thing: you added a lot of explicit types across the files. For example, types used only for struct imports aren’t needed if references to the shared utility are removed.

It may be worth running the type check with only the tsconfig changes introduced in this PR. That should reduce the number of required explicit types and shrink the review surface.

@ulissesferreira

Copy link
Copy Markdown
Contributor Author

@ulissesferreira, GG—nice work. I spotted one thing: you added a lot of explicit types across the files. For example, types used only for struct imports aren’t needed if references to the shared utility are removed.

It may be worth running the type check with only the tsconfig changes introduced in this PR. That should reduce the number of required explicit types and shrink the review surface.

Great catch! My patience was running thin, iterating on this again 🙏, we are close

@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from 252b66a to 7a9a986 Compare September 2, 2026 11:21
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch 3 times, most recently from 126aa43 to 33ef3a1 Compare September 2, 2026 11:45

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Changed these to match the other Snaps

@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from 33ef3a1 to 4d80491 Compare September 2, 2026 11:47
@ulissesferreira
ulissesferreira force-pushed the chore/enable-snap-typescript-check branch from 4d80491 to c15fdda Compare September 2, 2026 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants