Repository navigation
Fix/npm-pkg-shared-backend - #1598
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthrough
Changesshared-backend Build Pipeline and Publication Setup
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested reviewers
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryThis PR promotes
Confidence Score: 5/5Safe to merge — the changes faithfully replicate the existing publishable-package pattern from @hexclave/shared, and the only source-code edit is removing dead code that could never execute. All three changes are low-risk: the package.json restructuring mirrors the already-working @hexclave/shared layout, the new tsdown config delegates to a proven shared helper with no custom options, and the removed null-check in src/index.ts was guarding a condition the regex structure makes impossible. No files require special attention. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Consumer requires/imports @hexclave/shared-backend] --> B{Resolution condition}
B -->|require CJS| C["dist/index.js (CJS)"]
B -->|import ESM / default| D["dist/esm/index.js (ESM)"]
B -->|TypeScript types| E["dist/index.d.ts"]
F[Source: src/index.ts\nsrc/config-agent.ts\netc.] -->|tsdown build| G[dist/ — CJS output]
F -->|tsdown build| H[dist/esm/ — ESM output]
F -->|tsdown build| I[dist/*.d.ts — type declarations]
G --> C
H --> D
I --> E
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
A[Consumer requires/imports @hexclave/shared-backend] --> B{Resolution condition}
B -->|require CJS| C["dist/index.js (CJS)"]
B -->|import ESM / default| D["dist/esm/index.js (ESM)"]
B -->|TypeScript types| E["dist/index.d.ts"]
F[Source: src/index.ts\nsrc/config-agent.ts\netc.] -->|tsdown build| G[dist/ — CJS output]
F -->|tsdown build| H[dist/esm/ — ESM output]
F -->|tsdown build| I[dist/*.d.ts — type declarations]
G --> C
H --> D
I --> E
Reviews (1): Last reviewed commit: "chore: update package.json to exclude te..." | Re-trigger Greptile |
Summary by cubic
Prepares
@hexclave/shared-backendfor npm publishing with a proper build, dual ESM/CJS exports, and bundled types. Also simplifies an import parsing helper for safer matching.New Features
tsdown; output CJS/ESM and.d.tstodist/anddist/esm/..and./config-agentwithrequireanddefaultentries plus types.main/typesto built files, include onlydist, exclude tests, and addbuild,dev,cleanscripts.tsdown.config.ts.Bug Fixes
src/index.tsto push matches directly and remove unnecessary error throwing.Written for commit 9f18bc0. Summary will update on new commits.
Summary by CodeRabbit
Release Notes