forked from vitejs/vite
/
shims.d.ts
114 lines (94 loc) · 2.29 KB
/
shims.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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
declare module 'connect' {
const connect: () => any
export = connect
}
declare module 'cors' {
function cors(options: any): any
export = cors
}
declare module 'selfsigned' {
export function generate(attrs: any, options: any, done?: any): any
}
declare module 'http-proxy' {
const proxy: any
export = proxy
}
declare module 'acorn-class-fields' {
const plugin: any
export = plugin
}
declare module 'acorn-static-class-features' {
const plugin: any
export default plugin
}
declare module 'connect-history-api-fallback' {
const plugin: any
export = plugin
}
declare module 'launch-editor-middleware' {
const plugin: any
export = plugin
}
declare module 'merge-source-map' {
export default function merge(oldMap: object, newMap: object): object
}
declare module 'postcss-load-config' {
import { ProcessOptions, Plugin } from 'postcss'
function load(
inline: any,
root: string
): Promise<{
options: ProcessOptions
plugins: Plugin[]
}>
export = load
}
declare module 'postcss-import' {
import { Plugin } from 'postcss'
const plugin: (options: {
resolve: (
id: string,
basedir: string,
importOptions: any
) => string | string[] | Promise<string | string[]>
}) => Plugin
export = plugin
}
declare module 'postcss-modules' {
import { Plugin } from 'postcss'
const plugin: (options: any) => Plugin
export = plugin
}
declare module '@rollup/plugin-dynamic-import-vars' {
import { Plugin } from 'rollup'
interface Options {
include?: string | RegExp | (string | RegExp)[]
exclude?: string | RegExp | (string | RegExp)[]
warnOnError?: boolean
}
const p: (o?: Options) => Plugin
export default p
}
declare module 'rollup-plugin-web-worker-loader' {
import { Plugin } from 'rollup'
interface Options {
targetPlatform?: string
pattern?: RegExp
extensions?: string[]
sourcemap?: boolean
inline?: boolean
}
const p: (o?: Options) => Plugin
export default p
}
declare module 'minimatch' {
function match(path: string, pattern: string): boolean
export default match
}
declare module 'compression' {
function compression(): any
export default compression
}
// LESS' types somewhat references this which doesn't make sense in Node,
// so we have to shim it
declare interface HTMLLinkElement {}