Skip to content

chore: fix oxlint warnings (unused variables and imports)#35249

Open
sicnuyudidi wants to merge 1 commit intolanggenius:mainfrom
sicnuyudidi:fix/oxlint-warnings-25189
Open

chore: fix oxlint warnings (unused variables and imports)#35249
sicnuyudidi wants to merge 1 commit intolanggenius:mainfrom
sicnuyudidi:fix/oxlint-warnings-25189

Conversation

@sicnuyudidi
Copy link
Copy Markdown

Fixes #25189

What changed

Fixed 55 oxlint warnings across 20 files in the web/ directory:

  • Unused React imports (4 test files): Prefixed with _ in vi.mock callbacks
  • Unused type alias (types/doc-paths.ts): Removed unused DifyDocPath type
  • Useless escape chars (8 test/script files): Removed unnecessary backslashes
  • Useless fallback in spread (5 files): Changed ...(x ?? {}) to ...x
  • Prefer endsWith (scripts/check-i18n.js): Replaced regex with .endsWith(".json")
  • Unsafe optional chaining (use-workflow-run.spec.ts): Extracted intermediate variable
  • Unused expression (public/embed.js): Converted ternary to if/else block

All project source code warnings are now resolved. Remaining warnings are from third-party Monaco Editor files in public/vs/.

…#25189)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Apr 15, 2026
@github-actions github-actions bot added the web This relates to changes on the web. label Apr 15, 2026
@dosubot dosubot bot added the javascript Pull requests that update javascript code label Apr 15, 2026
@asukaminato0721 asukaminato0721 requested a review from hyoban April 15, 2026 08:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

javascript Pull requests that update javascript code size:M This PR changes 30-99 lines, ignoring generated files. web This relates to changes on the web.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Chore/Refactor] fix warnings by npx oxlint

1 participant