Skip to content

Conversation

@connorshea
Copy link
Contributor

Part of #14743.

Generated docs:

## Configuration

This rule accepts a configuration object with the following properties:

### preferInline

type: `boolean`

default: `false`

When set to `true`, prefer inline type imports instead of separate type import
statements for TypeScript code.

Examples of **correct** code with this option set to `true`:
\```typescript
import { Foo, type Bar } from './module';
\```

Copilot AI review requested due to automatic review settings October 30, 2025 15:22
@connorshea connorshea requested a review from camc314 as a code owner October 30, 2025 15:22
@github-actions github-actions bot added the A-linter Area - Linter label Oct 30, 2025
@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 30, 2025

How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

@github-actions github-actions bot added the C-docs Category - Documentation. Related to user-facing or internal documentation label Oct 30, 2025
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 adds schema configuration support for the no-duplicates import rule, enabling the preferInline option to be properly documented and validated through JSON schema. This allows users to configure whether TypeScript code should prefer inline type imports over separate type import statements.

  • Added JsonSchema derive and serde attribute to the NoDuplicates struct
  • Added documentation for the prefer_inline field
  • Registered the configuration in the declare_oxc_lint! macro

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@camc314 camc314 merged commit 18274aa into oxc-project:main Oct 30, 2025
25 checks passed
@codspeed-hq
Copy link

codspeed-hq bot commented Oct 30, 2025

CodSpeed Performance Report

Merging #15137 will not alter performance

Comparing connorshea:no-duplicates-docs (9e4a415) with main (297176c)

Summary

✅ 4 untouched
⏩ 33 skipped1

Footnotes

  1. 33 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@Boshen Boshen mentioned this pull request Nov 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-linter Area - Linter C-docs Category - Documentation. Related to user-facing or internal documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants