Skip to content

Conversation

@ijlee2
Copy link
Owner

@ijlee2 ijlee2 commented Jan 28, 2026

Background

The directories field in a package.json is unnecessary for ESM packages.

The CommonJS Packages spec details a few ways that you can indicate the structure of your package using a directories object. If you look at npm's package.json, you'll see that it has directories for doc, lib, and man.

In the future, this information may be used in other creative ways.

https://docs.npmjs.com/cli/v8/configuring-npm/package-json#directories

@ijlee2 ijlee2 added the enhance: documentation Issue asks for better documentation (e.g. README, code, tests) label Jan 28, 2026
@ijlee2 ijlee2 marked this pull request as ready for review January 28, 2026 07:08
@ijlee2 ijlee2 merged commit 8dc3c75 into main Jan 28, 2026
3 checks passed
@ijlee2 ijlee2 deleted the remove-directories-field branch January 28, 2026 07:08
@ijlee2 ijlee2 mentioned this pull request Jan 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhance: documentation Issue asks for better documentation (e.g. README, code, tests)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant