{"id":13774924,"url":"https://github.com/ritz078/rollup-plugin-filesize","last_synced_at":"2025-04-12T18:49:14.984Z","repository":{"id":37549797,"uuid":"50178312","full_name":"ritz078/rollup-plugin-filesize","owner":"ritz078","description":"A rollup plugin to show file size of the bundle in the cli","archived":false,"fork":false,"pushed_at":"2023-02-27T15:43:40.000Z","size":961,"stargazers_count":129,"open_issues_count":14,"forks_count":26,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-05-02T00:15:34.813Z","etag":null,"topics":["cli","rollup","rollup-plugin","theme"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ritz078.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-01-22T11:49:07.000Z","updated_at":"2024-06-18T12:35:05.161Z","dependencies_parsed_at":"2024-06-18T12:44:39.721Z","dependency_job_id":null,"html_url":"https://github.com/ritz078/rollup-plugin-filesize","commit_stats":{"total_commits":119,"total_committers":22,"mean_commits":5.409090909090909,"dds":0.4453781512605042,"last_synced_commit":"10b9fdd270432cb07405a481e5a3e0c0a061ec21"},"previous_names":[],"tags_count":24,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ritz078%2Frollup-plugin-filesize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ritz078%2Frollup-plugin-filesize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ritz078%2Frollup-plugin-filesize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ritz078%2Frollup-plugin-filesize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ritz078","download_url":"https://codeload.github.com/ritz078/rollup-plugin-filesize/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248618218,"owners_count":21134199,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","rollup","rollup-plugin","theme"],"created_at":"2024-08-03T17:01:31.810Z","updated_at":"2025-04-12T18:49:14.961Z","avatar_url":"https://github.com/ritz078.png","language":"JavaScript","funding_links":[],"categories":["Plugins"],"sub_categories":["Output"],"readme":"# rollup-plugin-filesize\n\n\u003e A rollup plugin to show filesize in the cli\n\n![](screen.png)\n\n## Installation\n\n```\nnpm install rollup-plugin-filesize\n```\n\n## Usage\n\n```js\nimport { rollup } from 'rollup';\nimport filesize from 'rollup-plugin-filesize';\n\nrollup({\n  entry: 'main.js',\n  plugins: [\n    filesize()\n  ]\n}).then(...)\n```\n\n## options\n\n#### showMinifiedSize\n\ntype: `boolean`\ndefault: true\n\nWhether to show minified size or not\n\n#### showGzippedSize\n\ntype: `boolean`\ndefault: true\n\nWhether to show Gzipped size or not\n\n#### showBrotliSize\n\ntype: `boolean`\ndefault: false\n\nWhether to show [Brotli](https://www.wikiwand.com/en/Brotli) size or not\n\n#### showBeforeSizes\n\n**Note: this feature is experimental and may be changed in a future release.**\n\ntype: `\"release\"`, `\"build\"`, or `\"none\"`\ndefault: `\"none\"`\n\nIndicates how, if any, comparisons will be shown between the\n`output.file` file size as it was and as it is now being written.\n\nIf set to `\"release\"`, will compare the file size at present to that of\nthe last npm release.\n\nIf set to `\"build\"`, the size of the file that is now being built will\nbe compared to the immediately previous build. This means that if you run\nRollup multiple times with this option, the info on the previous package\nsize will be lost (since Rollup will have overwritten your copy), so with\nthis option, you will need to consult your terminal history to see what the\nfile size was prior to your changes. This option may be useful if you wish\nto compare size changes incrementally as you are developing rather than\ncomparing to your last release.\n\n#### format\n\ntype : `object`\n\ndefault : {}\n\nSee the options [here](https://github.com/avoidwork/filesize.js#optional-settings)\n\n#### reporter\n\n(Note that this replaces the deprecated optional `render` function option.)\n\ntype : A reporter string (currently \"boxen\" only), a function, or an array thereof.\n\nDefaults to \"boxen\".\n\nAfter rendering occurs, you may wish to pass on the collected file data,\ne.g., to build a badge for filesizes (as does [filesize-badger](https://github.com/brettz9/filesize-badger)).\n\nYou can use `reporter` to do so:\n\n```js\nfilesize({\n\treporter: [\n\t\tfunction (options, bundle, {\n\t\t\tminSize, gzipSize, brotliSize, bundleSize,\n\t\t\tfileName,\n\t\t\t// \"showBeforeSizes: release\"\n\t\t\tlastVersion,\n\t\t\t// \"showBeforeSizes: \"release\" or \"showBeforeSizes\": \"build\"\n\t\t\tbundleSizeBefore, brotliSizeBefore, minSizeBefore, gzipSizeBefore\n\t\t}) {\n\t\t\t// If a promise is returned, it will be awaited before rendering.\n\t\t\treturn promise;\n\t\t},\n\t],\n});\n```\n\n#### theme\n\ntype: `string`\n\ndefault : 'dark'\n\noptions : 'dark'/'light'\n\nchoose based on your terminal theme.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fritz078%2Frollup-plugin-filesize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fritz078%2Frollup-plugin-filesize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fritz078%2Frollup-plugin-filesize/lists"}