Skip to content

Comments

feat(napi): export all options using wildcard exports#15663

Closed
Boshen wants to merge 0 commit intomainfrom
feat/napi-export-all-options
Closed

feat(napi): export all options using wildcard exports#15663
Boshen wants to merge 0 commit intomainfrom
feat/napi-export-all-options

Conversation

@Boshen
Copy link
Member

@Boshen Boshen commented Nov 13, 2025

Closes #15618

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings November 13, 2025 07:43
@graphite-app
Copy link
Contributor

graphite-app bot commented Nov 13, 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 A-parser Area - Parser A-minifier Area - Minifier C-enhancement Category - New feature or request labels Nov 13, 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 modernizes the export strategy for three NAPI packages by switching from selective exports to wildcard exports (pub use module::*), ensuring all option types and supporting types are properly exposed to TypeScript/JavaScript consumers. This addresses issue #15618 where TreeShakeOptions and other types were missing from the public API.

  • Replaced selective exports with wildcard exports in minify, parser, and playground packages
  • Added missing TypeScript documentation for sort import options
  • Removed redundant import statements in playground

Reviewed Changes

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

File Description
napi/minify/src/lib.rs Changed from selective exports to wildcard export to expose all minify option types including TreeShakeOptions
napi/parser/src/lib.rs Changed from selective exports to wildcard export to expose all module record types (Span, ImportName, etc.)
napi/playground/src/lib.rs Added wildcard export and removed redundant imports that are now exported via the wildcard
napi/playground/index.d.ts Updated TypeScript declarations with new sort import options fields (newlinesBetween, groups) and improved documentation

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

@Boshen Boshen added the 0-merge Merge with Graphite Merge Queue label Nov 13, 2025
Copy link
Member Author

Boshen commented Nov 13, 2025

Merge activity

  • Nov 13, 7:52 AM UTC: The merge label '0-merge' was detected. This PR will be added to the Graphite merge queue once it meets the requirements.
  • Nov 13, 7:55 AM UTC: Boshen added this pull request to the Graphite merge queue.

@graphite-app graphite-app bot closed this Nov 13, 2025
@graphite-app graphite-app bot force-pushed the feat/napi-export-all-options branch from 6134c64 to f5ce55a Compare November 13, 2025 07:56
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Nov 13, 2025
@Boshen Boshen deleted the feat/napi-export-all-options branch December 1, 2025 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-minifier Area - Minifier A-parser Area - Parser C-enhancement Category - New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant