Skip to content

Conversation

@YDX-2147483647
Copy link
Contributor

@YDX-2147483647 YDX-2147483647 commented Sep 5, 2025

This PR removes unused imports in TS/TSX files.

I noticed them when developing #294, and enabled the rule noUnusedImports | Biome locally.

noUnusedImports raises warnings in biome v2 by default. In biome v1, it is supported, but emits nothing by default.
I guess v1 hadn't implemented the rule well at that time, so it wasn't enabled by default.

I suggest upgrading to biome v2, but that would be a huge PR. It's best to have it done by a typst-jp member later (when you have time).

@3w36zj6 3w36zj6 requested review from 3w36zj6 and Copilot September 5, 2025 02:41
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes unused imports from TypeScript/TSX files to improve code cleanliness and follows best practices by eliminating dead code. The changes were identified using Biome's noUnusedImports rule and prepare the codebase for potential future upgrades to Biome v2.

  • Removed unused type imports (Body type)
  • Removed unused component imports (SiteTitle)
  • Removed unused utility function imports (type2href, FunctionDefinition, FunctionParameters)
  • Removed unused metadata imports (githubOrganizationUrl)

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
website/src/index.tsx Removed unused Body type import
website/src/components/ui/common/SideNavigation.tsx Removed unused SiteTitle component import
website/src/components/ui/common/Footer.tsx Removed unused githubOrganizationUrl import
website/src/components/templates/TypeTemplate.tsx Removed unused type2href utility function import
website/src/components/templates/GroupTemplate.tsx Removed unused FunctionDefinition and FunctionParameters component imports

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@3w36zj6 3w36zj6 changed the title style: remove unused imports refactor: remove unused imports Sep 5, 2025
@3w36zj6 3w36zj6 merged commit 2b1f17f into typst-jp:main Sep 5, 2025
5 checks passed
@YDX-2147483647 YDX-2147483647 deleted the import branch September 5, 2025 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants