Detect duplicate packaged dependencies
npm i -D unplugin-detect-duplicated-deps@0
You can use the jsdoc to check option description and default value.
Vite
// vite.config.ts
import UnpluginDetectDuplicatedDeps from 'unplugin-detect-duplicated-deps/vite';
export default defineConfig({
plugins: [UnpluginDetectDuplicatedDeps()],
});
Rollup
// rollup.config.js
import UnpluginDetectDuplicatedDeps from 'unplugin-detect-duplicated-deps/rollup';
export default {
plugins: [UnpluginDetectDuplicatedDeps()],
};
- duplicate-package-checker-webpack-plugin
- unplugin
- unplugin-starter
- bundlephobia provide the api to get package size
MIT License © 2023-PRESENT YuTengjing