feat: Add per-function granular exports for all groups#1668
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
Adds wildcard subpath exports to support per-function deep imports (e.g. es-toolkit/function/debounce) across the main groups, and updates build/test tooling to accommodate these new export patterns.
Changes:
- Add
./<group>/*wildcard entries toexportsandpublishConfig.exportsfor granular imports. - Update Rollup entrypoint resolution to ignore wildcard export targets.
- Expand
.attw.jsonentrypoint sampling for types validation.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
package.json |
Adds wildcard subpath exports for each group (and corresponding published dist mappings). |
rollup.config.mjs |
Filters wildcard export targets out of Rollup entrypoint discovery. |
tests/check-dist.spec.ts |
Updates expected export subpaths to include the new wildcards. |
.attw.json |
Adds representative granular entrypoints for type-check tooling. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
aa42772 to
a870507
Compare
a870507 to
8373dba
Compare
8373dba to
59518ec
Compare
59518ec to
a777685
Compare
|
@nunomarks does this handle |
bf90e52 to
4a58c10
Compare
4a58c10 to
8337889
Compare
Made that change, thank you, overlooked that. Please review when you can. |
7c0968b to
4a70661
Compare
4a70661 to
8e97203
Compare
| { | ||
| "format": "table-flipped", | ||
| "emoji": false, | ||
| "profile": "node16", |
There was a problem hiding this comment.
node10 does not support subpath exports. It is also very ancient, so I'm not sure you'd want to support it. For now I'm suggesting to ignore it. This profile field is only supported on the 0.17.x version of the attw CLI
8e97203 to
8cd5640
Compare
8cd5640 to
931c6d5
Compare
931c6d5 to
daf9210
Compare
|
@niksy can this be reviewed again ? |
niksy
left a comment
There was a problem hiding this comment.
I think this looks OK, but final word should be from the maintainers.
Context
Changes
Enable deep imports like `es-toolkit/function/debounce` for all main groups (error, function, map, math, object, predicate, promise, set, string, util).