fix(assist): resolve oxlint violations instead of suppressing rules#659
Draft
fix(assist): resolve oxlint violations instead of suppressing rules#659
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: 6861d2e The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
…pread, no-map-spread, no-base-to-string Co-authored-by: pedrobonamin <46196328+pedrobonamin@users.noreply.github.com>
…ted (FormEvent, marker.item, throwError) Co-authored-by: pedrobonamin <46196328+pedrobonamin@users.noreply.github.com>
…Event), no-await-in-loop in SchemTypeTool Co-authored-by: pedrobonamin <46196328+pedrobonamin@users.noreply.github.com>
…ontext, AssistDocumentPresence Co-authored-by: pedrobonamin <46196328+pedrobonamin@users.noreply.github.com>
Co-authored-by: pedrobonamin <46196328+pedrobonamin@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix issues instead of disabling oxlint rules
fix(assist): resolve oxlint violations instead of suppressing rules
Mar 6, 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.
Audit all oxlint/eslint disable comments in
plugins/@sanity/assistand fix the underlying issues where possible. Removed 32 suppression comments across 20 files.Performance & correctness
prefer-set-has:inlineTypesarray →SetinserializeSchema.tsno-accumulating-spread: Refactoredreduce+ spread →for/pushinconditionalMembers.ts,helpers.ts,paths.tsno-map-spread:Object.assign()or restructured away from spreading in.map()across 5 filesDeprecated API migrations
@sanity/uitheme:theme.sanity.color.base.*→useTheme_v2()+theme.color.*inConnectorPath.tsxrgba:@sanity/ui→@sanity/ui/themeuseClickOutside→useClickOutsideEventwith ref-based API inInstructionTaskHistoryButton.tsxReact.FormEvent→SyntheticEvent/ChangeEvent(deprecated in React 19)marker.item.message→marker.messagein validation componentsthrowError(new Error(...))→throwError(() => new Error(...))(RxJS factory form)React hooks & compiler compatibility
react-hooks/exhaustive-deps: Added missing deps (getUserInput,addSyntheticTask,removeSyntheticTask); used refs for mount-only effects inPromptInput.tsxreact-hooks-js/todo: Removed unnecessary?.after array spread; replacedtry/finallywithtry/catchfor React Compiler HIR compatibilityreact-hooks-js/set-state-in-effect: Replaced state tracking withuseRefinImageContext.tsxType & lint fixes
no-redundant-type-constituents:ElementType | ReactNode→ElementTypeno-base-to-string:String(type.type)→type.type?.name ?? 'unknown'react/no-array-index-key: Content-based keys using path strings and messagesno-await-in-loop/await-thenable: SeparatedcreateOrReplace(sync builder) fromcommit(async) in batch loopRemaining 83 suppressions
Mostly
no-unsafe-type-assertion(73) — inherent to Sanity's loosely-typed schema/form APIs. The rest are intentional patterns: forced re-renders viasetStatein effects,usePreviousref reads during render, dynamic hook calls from user config, and a side-effect module augmentation import.Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
sanity-cdn.com/home/REDACTED/work/_temp/ghcca-node/node/bin/node node /home/REDACTED/work/plugins/plugins/dev/test-studio/node_modules/.bin/../sanity/bin/sanity build grep modules/.bin/../@sanity/pkg-utils/bin/pkg-utils.js -report-unused-d--clean gins nfig/composer/vendor/bin/git useTheme_v2 _react-is@_868e2/home/REDACTED/work/_temp/ghcca-node/node/bin/pnpm tnet/tools/grep grep bin/�� rd node_modules/.pnpm/@sanity+ui@3.1.13_@emotion+is-prop-valid@1.4.0_react-dom@19.2.4_react@19.2.4_--service=0.27.3 de/node/bin/sh useTheme_v2 .4_react@19.2.4_-c ep grep(dns block)If you need me to access, download, or install something from one of these locations, you can either:
🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.