fix(deps): move runtime dependencies to devDependencies#225
Merged
Conversation
All packages are bundled at build time via esbuild (npm) and Bun.build (standalone binaries), so runtime dependencies are unnecessary and would force consumers to install them needlessly. - Move ignore, p-limit, pretty-ms from dependencies to devDependencies - Add script/check-no-deps.ts CI check that fails if dependencies exist - Add check:deps script to package.json, wired into CI lint job - Add test/package.test.ts for local regression catching
Contributor
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨Cli
Other
Bug Fixes 🐛Upgrade
Other
Documentation 📚
Internal Changes 🔧
🤖 This preview updates automatically when you update the PR. |
Contributor
Codecov Results 📊✅ Patch coverage is 100.00%. Project has 3947 uncovered lines. Files with missing lines (64)
Coverage diff@@ Coverage Diff @@
## main #PR +/-##
==========================================
+ Coverage 67.47% 67.47% —%
==========================================
Files 99 99 —
Lines 12133 12133 —
Branches 0 0 —
==========================================
+ Hits 8186 8186 —
- Misses 3947 3947 —
- Partials 0 0 —Generated by Codecov Action |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
All packages are bundled at build time via esbuild (npm) and
Bun.build(standalone binaries), so thedependenciesfield should always be empty. Three packages (ignore,p-limit,pretty-ms) were accidentally listed there.ignore,p-limit,pretty-msfromdependenciestodevDependenciesdependenciesfieldscript/check-no-deps.tsCI check that fails ifdependenciesexists inpackage.jsoncheck:depsinto the CI lint job alongsidebun run lintandbun run typechecktest/package.test.tsunit test for local regression catchingVerification
bun run typecheck— passesbun run lint— passesbun run check:deps— passesbun run bundle— produces workingdist/bin.cjsnode dist/bin.cjs --help— worksbun test test/package.test.ts— passes