Repository navigation
chore(app): enable noUnusedLocals - #52856
Merged
Merged
Conversation
This was referenced Oct 2, 2026
kitlangton
force-pushed
the
unused-locals-app
branch
from
October 2, 2026 22:28
3c52f43 to
f6d7eb1
Compare
kitlangton
enabled auto-merge (squash)
October 2, 2026 22:29
Ichinose-Kazuki
pushed a commit
to Ichinose-Kazuki/opencode
that referenced
this pull request
Oct 7, 2026
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.
Why
Every package tsconfig extends
@tsconfig/bun, which defaultsnoUnusedLocalstofalse. Nobody turned it off deliberately, so unused code in app went undetected. This turns the flag on for app (and its e2e config, which extends it) and removes the 26 unused locals it finds.What Changes
packages/app/tsconfig.json:"noUnusedLocals": truesettings/general/general.tsx: deletes the deadAppearanceSectionandNotificationsSectioncomponents and their helpers (FontSetting,fontSettings,schemeOptions, plus imports). feat(app): redesign non-modal settings #40845 moved both sections to their own settings pages and stopped rendering these; the old code stayed behind.shell/notifications/notification.tsx: 10 unused imports.shell/tabs/tabs.tsx: unuseduseParams()call and import (read-only router access).composer/editor/editor.tsx,providers/connect/dialog.tsx,shell/commands/palette.ts,shell/titlebar/tab-nav.tsx.typecheck:e2e, which extends app's config): 3 unused imports, and an unusedtimelinebinding inscroll-interaction.spec.ts. ThesetupTimeline(...)call is kept.No behavior changes.
Scope
Part of a series enabling
noUnusedLocalsper package (#52849, #52850).typecheck:e2estill reports two existingTS2345errors (terminals/probe.ts,session-timeline-stream-probe.ts) that are onv2already and unrelated.Verification
Typecheck clean; 728 unit tests pass, 0 fail.