File tree Expand file tree Collapse file tree 2 files changed +41
-1
lines changed Expand file tree Collapse file tree 2 files changed +41
-1
lines changed Original file line number Diff line number Diff line change
1
+ import { Plugin } from "rollup" ;
2
+
3
+ declare const analyzer : ( options ?: AnalyzerOptions ) => Plugin ;
4
+ export default analyzer ;
5
+
6
+ export interface AnalyzerOptions {
7
+ stdout ?: boolean ;
8
+ limit ?: number ;
9
+ filter ?: string | string [ ] | ( ( id : string ) => boolean ) ;
10
+ root ?: string ;
11
+ hideDeps ?: boolean ;
12
+ showExports ?: boolean ;
13
+ summaryOnly ?: boolean ;
14
+ skipFormatted ?: boolean ;
15
+ writeTo ?: ( analysisString : string ) => void ;
16
+ transformModuleId ?: ( id : string ) => string ;
17
+ onAnalysis ?: ( analysisObject : AnalysisObject ) => void ;
18
+ }
19
+
20
+ export interface AnalysisObject {
21
+ bundleSize : number ;
22
+ bundleOrigSize : number ;
23
+ bundleReduction : number ;
24
+ moduleCount : number ;
25
+ modules : Module [ ] ;
26
+ }
27
+
28
+ export interface Module {
29
+ id : string ;
30
+ size : number ;
31
+ origSize : number ;
32
+ dependents : string [ ] ;
33
+ percent : number ;
34
+ reduction : number ;
35
+ usedExports : string [ ] ;
36
+ unusedExports : string [ ] ;
37
+ }
Original file line number Diff line number Diff line change 2
2
"name" : " rollup-plugin-analyzer" ,
3
3
"version" : " 3.2.2" ,
4
4
"description" : " Mad metrics for your rollup bundles, know all the things" ,
5
- "engines" : { "node" : " >=8.0.0" },
5
+ "engines" : {
6
+ "node" : " >=8.0.0"
7
+ },
6
8
"main" : " index.js" ,
7
9
"module" : " module.js" ,
8
10
"files" : [
9
11
" index.js" ,
12
+ " index.d.ts" ,
10
13
" module.js"
11
14
],
12
15
"scripts" : {
You can’t perform that action at this time.
0 commit comments