Repository navigation
chore: remove unused dependencies and exports - #746
Conversation
Findings from `npx fallow dead-code`: - drop `magic-string` (unhead), `oxc-parser` (react/solid-js/svelte and their build externals), `fs-extra`, `@types/fs-extra`, `rollup-plugin-analyzer`, `utility-types` from root, plus unused example-only deps (`react-router-dom`, `rollup-plugin-visualizer`, `vite-bundle-analyzer`, `@solidjs/testing-library`, `vite-plugin-solid`) - add `@rollup/plugin-node-resolve` and `rollup` as explicit devDeps of `packages/unhead` (previously imported from `build.config.ts` with `@ts-expect-error` workarounds) - convert `NAMESPACES` and `MetaPackingSchema` in `unhead/utils/meta.ts` to internal (only used in-file) - unexport helper thenables in the react-streaming example cache
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (14)
💤 Files with no reviewable changes (6)
📝 WalkthroughWalkthroughThis pull request removes the Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ 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 |
Summary
Cleanup pass based on
npx fallow dead-code. All changes verified withpnpm build,pnpm vitest run,pnpm typecheck, andpnpm lint.magic-stringfromunheadoxc-parserfrom@unhead/react,@unhead/solid-js,@unhead/svelte(+ their buildexternals)fs-extra,@types/fs-extra,rollup-plugin-analyzer,utility-types@solidjs/testing-library,vite-plugin-solidrollup-plugin-visualizerandvite-bundle-analyzer(vite-ssr-vue),react-router-dom(vite-ssr-react-ts)pnpm-workspace.yaml) entries for the above@rollup/plugin-node-resolve+rollupas explicit devDeps ofpackages/unhead(previously imported frombuild.config.tswith@ts-expect-errorworkarounds, now properly typed)NAMESPACES,MetaPackingSchemainpackages/unhead/src/utils/meta.ts(only referenced in-file)resolvedThenable,delayedPromiseinexamples/vite-ssr-react-streaming/src/utils/cache.tsKept (fallow false-positives):
packages/unhead/src/parser/index.tsexports (TagIdMap,parseAttributes, etc.) are public API, snapshotted intest/exports/unhead.yamlpackages/angularcomposables, exposed viapublic-api.tswhich fallow couldn't resolve (ng-packagr)Head.updateHeadhas direct test coverage@vueuse/nuxtis registered innuxt.config.tsmodulesTest plan
pnpm installpnpm buildpnpm vitest run(1272 passed, 8 skipped)pnpm typecheckpnpm lintSummary by CodeRabbit