Skip to content

fix(oxlint): add configuration_schema.json to package exports#19459

Open
shibanet0 wants to merge 1 commit intooxc-project:mainfrom
shibanet0:fix/export-configuration-schema
Open

fix(oxlint): add configuration_schema.json to package exports#19459
shibanet0 wants to merge 1 commit intooxc-project:mainfrom
shibanet0:fix/export-configuration-schema

Conversation

@shibanet0
Copy link

The configuration_schema.json file was not accessible after adding the exports field in #18601. This adds the missing export entry.

Fixes the import: import schema from 'oxlint/configuration_schema.json'

The configuration_schema.json file was not accessible after adding the `exports` field in oxc-project#18601. This adds the missing export entry.

Fixes the import: `import schema from 'oxlint/configuration_schema.json'`
@github-actions github-actions bot added the C-bug Category - Bug label Feb 16, 2026
@shibanet0
Copy link
Author

@camc314 @overlookmotel - this is a small fix for a regression introduced in #18601. The configuration_schema.json became inaccessible after the exports field was added.

Would appreciate a review when you have a moment!

@camc314
Copy link
Contributor

camc314 commented Feb 22, 2026

i don't think It was never intentional that this was exposed - why do you need to import it?

@shibanet0
Copy link
Author

I maintain a shared config package that aggregates and re-exports configurations and schemas from various tools (ESLint, Prettier, etc.) so they can be reused across multiple projects without duplicating dependencies.

For oxlint specifically, I need to programmatically access configuration_schema.json to re-export it - so consumers of my package can use the schema for editor validation or config generation without depending on oxlint directly.

The alternative is to resolve it via require.resolve / import.meta.resolve and read the file from node_modules manually, but a proper exports entry is the idiomatic Node.js way to expose a file from a package. The schema file already exists in the package — this PR just makes it officially accessible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-bug Category - Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants