UNPKG

2.36 kBMarkdownView Raw
1# Installation
2> `npm install --save @types/rollup-plugin-visualizer`
3
4# Summary
5This package contains type definitions for rollup-plugin-visualizer (https://github.com/doesdev/rollup-plugin-analyzer#readme).
6
7# Details
8Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/rollup-plugin-visualizer.
9## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/rollup-plugin-visualizer/index.d.ts)
10````ts
11import { Plugin } from "rollup";
12
13declare namespace visualizer {
14 interface PluginVisualizerOptions {
15 /**
16 * Name of the file with diagram to generate
17 * @default "stats.html"
18 */
19 filename?: string | undefined;
20 /**
21 * Title tag value
22 * @default "Rollup Visualizer"
23 */
24 title?: string | undefined;
25 /**
26 * Use sourcemaps to calculate sizes (e.g. after UglifyJs or Terser)
27 * @default false
28 */
29 sourcemap?: boolean | undefined;
30 /**
31 * Open generated file in default user agent
32 * @default false
33 */
34 open?: boolean | undefined;
35 /**
36 * Which diagram type to use
37 * @default "treemap"
38 */
39 template?: "treemap" | "sunburst" | "network" | undefined;
40 /**
41 * Product portable json file that can be used with
42 * plugin CLI util to generate graph from several json files.
43 * Every UI property ignored in this case.
44 * @default false
45 */
46 json?: boolean | undefined;
47 /**
48 * Collect gzip size from source code and display it at chart
49 * @default false
50 */
51 gzipSize?: boolean | undefined;
52 /**
53 * Collect brotli size from source code and display it at chart.
54 * Only if current node version supports it
55 * @default false
56 */
57 brotliSize?: boolean | undefined;
58 }
59}
60
61declare function visualizer(options?: visualizer.PluginVisualizerOptions): Plugin;
62
63export = visualizer;
64
65````
66
67### Additional Details
68 * Last updated: Fri, 01 Mar 2024 00:50:47 GMT
69 * Dependencies: [rollup](https://npmjs.com/package/rollup)
70
71# Credits
72These definitions were written by [Nick](https://github.com/fobdy), and [Max Boguslavskiy](https://github.com/maxbogus).
73
\No newline at end of file