forked from vladshcherbin/rollup-plugin-copy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
62 lines (52 loc) · 1.27 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
import rollup from 'rollup';
import fs from 'fs-extra';
import globby from 'globby';
interface Target extends globby.GlobbyOptions {
/**
* Path or glob of what to copy.
*/
readonly src: string | readonly string[];
/**
* One or more destinations where to copy.
*/
readonly dest: string | readonly string[];
/**
* Change destination file or folder name.
*/
readonly rename?: string | Function;
/**
* Modify file contents.
*/
readonly transform?: Function;
}
interface CopyOptions extends globby.GlobbyOptions, fs.CopyOptions {
/**
* Copy items once. Useful in watch mode.
* @default false
*/
readonly copyOnce?: boolean;
/**
* Remove the directory structure of copied files.
* @default true
*/
readonly flatten?: boolean;
/**
* Rollup hook the plugin should use.
* @default 'buildEnd'
*/
readonly hook?: string;
/**
* Array of targets to copy.
* @default []
*/
readonly targets?: readonly Target[];
/**
* Output copied items to console.
* @default false
*/
readonly verbose?: boolean;
}
/**
* Copy files and folders using Rollup
*/
export default function copy(options?: CopyOptions): rollup.Plugin;