@nejcm/rollup-plugin-size-snapshot-vite
TypeScript icon, indicating that this package has built-in type declarations

0.0.8 • Public • Published

rollup-plugin-size-snapshot

This plugin provides details about

  • actual bundle size (bundler parsing size)
  • minified bundle size (browser parsing size)
  • gzipped bundle size (download size)

All of these sizes are important criteria when choosing a library, and they will be stored in the .size-snapshot.json file.

Usage

Inside vite.config:

import { sizeSnapshot } from '@nejcm/rollup-plugin-size-snapshot-vite';

export default defineConfig({
  build: {
    rollupOptions: {
      plugins: [sizeSnapshot()],
    },
  },
});

Note: If your config file is as .ts file than casting to any might be required. E.g.: sizeSnapshot() as any

License

MIT © Bogdan Chadkin

Readme

Keywords

none

Package Sidebar

Install

npm i @nejcm/rollup-plugin-size-snapshot-vite

Weekly Downloads

108

Version

0.0.8

License

MIT

Unpacked Size

18.8 kB

Total Files

9

Last publish

Collaborators

  • nejcm