fix: biome & tsc setup across repo - #493
Merged
Merged
Conversation
Contributor
Greptile SummaryThis PR applies Biome formatter enforcement across the repository and sets up Key changes:
Confidence Score: 4/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[git commit] --> B{commit-msg hook\nConventional Commits?}
B -- No --> C[❌ Block commit\nexit 1]
B -- Yes --> D[pre-commit hooks]
D --> E[biome-check\nnpx @biomejs/biome check --write\nstage_fixed: true]
D --> F[file-length\nwc -l per staged .ts/.tsx]
F -- lines > 400 --> G[⚠️ Warn only\nno exit 1]
F -- lines ≤ 400 --> H[✅ Pass]
E --> I[✅ Auto-fixed & re-staged]
J[git push] --> K{branch-name check}
K -- matches pattern --> L[✅ Push proceeds]
K -- no match --> M[⚠️ Warn only\nno exit 1]
subgraph CI ["GitHub Actions: typecheck job"]
N[bun ci] --> O[wxt prepare\nVITE_PUBLIC_BROWSEROS_API=localhost]
O --> P[codegen]
P --> Q[tsgo --noEmit]
end
Prompt To Fix All With AIThis is a comment left during a code review.
Path: packages/browseros-agent/apps/agent/tsconfig.json
Line: 7-9
Comment:
**`baseUrl` removal may break `@/*` path aliases in editors**
`paths` entries like `"@/*": ["./*"]` are resolved relative to `baseUrl` in TypeScript's classic module resolution. Removing `"baseUrl": "."` means these relative paths no longer have an anchor point.
While WXT's auto-generated `.wxt/tsconfig.json` (which this file extends) likely provides its own `baseUrl`, editors that don't fully expand the extended chain (or run `tsgo` directly on this file) may fail to resolve `@/` imports. Removing `baseUrl` is safe if `.wxt/tsconfig.json` explicitly sets it, but worth verifying that IDEs still resolve `@/` aliases correctly after this change.
How can I resolve this? If you propose a fix, please make it concise.
---
This is a comment left during a code review.
Path: packages/browseros-agent/package.json
Line: 52
Comment:
**Dev snapshot dependency pinned to a specific daily build**
`@typescript/native-preview@^7.0.0-dev.20260319.1` is a nightly dev snapshot of the TypeScript native (Go) compiler. The `^` range prefix on a pre-release tag has non-obvious semver semantics — in most package managers, pre-release versions are not automatically bumped by `^`, so this effectively acts as a pinned version. However, since this is a daily dev build, the specific snapshot (`20260319.1`) may have known instability or missing features that differ from the stable `typescript` compiler also declared as a devDependency.
Consider documenting why this specific snapshot was chosen and when it can be replaced with a stable release, to avoid confusion for contributors.
How can I resolve this? If you propose a fix, please make it concise.Last reviewed commit: "fix: early return to..." |
Contributor
Author
Contributor
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces several improvements to code quality enforcement and refactors export orderings for UI components to ensure consistency and avoid subtle bugs. It also includes minor UI and code style tweaks for better maintainability and user experience.
Code Quality Enforcement and Tooling:
lefthook.ymlconfiguration to enforce Conventional Commits, check file length, run Biome formatting on staged files, and warn about non-standard branch names. This helps maintain code quality and consistency across the team.typecheckjob in the GitHub Actions workflow due to memory errors, with a note to fix it later.UI Component Export Refactoring:
alert-dialog.tsx,card.tsx,carousel.tsx,dropdown-menu.tsx, etc.) to ensure a consistent and logical export order, which can help prevent import-related bugs and improve developer experience. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]UI and Code Style Improvements:
ProviderCardcomponent, ensuring correct fallback and display order.Dependency and Import Order Cleanups:
These changes collectively improve code maintainability, enforce best practices, and address minor UI and code style issues.