@node-red/editor-client 2.0.4 → 2.1.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/locales/en-US/editor.json +37 -7
- package/locales/ko/editor.json +1 -1
- package/package.json +2 -2
- package/public/red/about +109 -0
- package/public/red/images/node-red-256.svg +1 -0
- package/public/red/keymap.json +13 -2
- package/public/red/red.js +6122 -3663
- package/public/red/red.min.js +1 -1
- package/public/red/style.min.css +2 -2
- package/public/red/tours/first-flow.js +80 -0
- package/public/red/tours/welcome.js +135 -0
- package/public/tours/first-flow.js +82 -0
- package/public/types/node/assert.d.ts +127 -0
- package/public/types/node/async_hooks.d.ts +229 -0
- package/public/types/node/buffer.d.ts +25 -1
- package/public/types/node/child_process.d.ts +514 -6
- package/public/types/node/cluster.d.ts +265 -0
- package/public/types/node/console.d.ts +136 -1
- package/public/types/node/crypto.d.ts +1189 -1
- package/public/types/node/dgram.d.ts +144 -1
- package/public/types/node/dns.d.ts +383 -10
- package/public/types/node/domain.d.ts +27 -1
- package/public/types/node/events.d.ts +81 -1
- package/public/types/node/fs.d.ts +2273 -1
- package/public/types/node/globals.d.ts +616 -1
- package/public/types/node/http.d.ts +489 -1
- package/public/types/node/http2.d.ts +961 -0
- package/public/types/node/https.d.ts +142 -0
- package/public/types/node/module.d.ts +55 -0
- package/public/types/node/net.d.ts +296 -1
- package/public/types/node/os.d.ts +242 -1
- package/public/types/node/path.d.ts +156 -1
- package/public/types/node/perf_hooks.d.ts +274 -0
- package/public/types/node/process.d.ts +412 -1
- package/public/types/node/querystring.d.ts +31 -1
- package/public/types/node/readline.d.ts +173 -0
- package/public/types/node/stream.d.ts +358 -0
- package/public/types/node/string_decoder.d.ts +10 -0
- package/public/types/node/timers.d.ts +19 -0
- package/public/types/node/tls.d.ts +783 -0
- package/public/types/node/trace_events.d.ts +64 -0
- package/public/types/node/tty.d.ts +69 -0
- package/public/types/node/url.d.ts +119 -1
- package/public/types/node/util.d.ts +210 -0
- package/public/types/node/v8.d.ts +190 -0
- package/public/types/node/vm.d.ts +155 -0
- package/public/types/node/wasi.d.ts +89 -0
- package/public/types/node/worker_threads.d.ts +241 -0
- package/public/types/node/zlib.d.ts +364 -0
- package/public/types/node-red/func.d.ts +1 -1
- package/public/types/node-red/util.d.ts +1 -1
- package/public/vendor/ace/worker-jsonata.js +1 -1
- package/public/vendor/monaco/dist/ThirdPartyNotices.txt +192 -192
- package/public/vendor/monaco/dist/css.worker.js +1 -1
- package/public/vendor/monaco/dist/editor.js +2 -2
- package/public/vendor/monaco/dist/editor.worker.js +1 -1
- package/public/vendor/monaco/dist/html.worker.js +1 -1
- package/public/vendor/monaco/dist/json.worker.js +1 -1
- package/public/vendor/monaco/dist/locale/cs.js +44 -10
- package/public/vendor/monaco/dist/locale/de.js +46 -12
- package/public/vendor/monaco/dist/locale/es.js +46 -12
- package/public/vendor/monaco/dist/locale/fr.js +43 -9
- package/public/vendor/monaco/dist/locale/it.js +45 -11
- package/public/vendor/monaco/dist/locale/ja.js +45 -11
- package/public/vendor/monaco/dist/locale/ko.js +44 -10
- package/public/vendor/monaco/dist/locale/pl.js +42 -8
- package/public/vendor/monaco/dist/locale/pt-br.js +49 -15
- package/public/vendor/monaco/dist/locale/qps-ploc.js +1445 -0
- package/public/vendor/monaco/dist/locale/ru.js +48 -14
- package/public/vendor/monaco/dist/locale/tr.js +49 -15
- package/public/vendor/monaco/dist/locale/zh-hans.js +48 -14
- package/public/vendor/monaco/dist/locale/zh-hant.js +45 -11
- package/public/vendor/monaco/dist/theme/monoindustrial.json +228 -0
- package/public/vendor/monaco/dist/theme/solarized-dark.json +1082 -0
- package/public/vendor/monaco/dist/ts.worker.js +2 -2
- package/public/vendor/vendor.js +4 -4
- package/templates/index.mst +5 -1
|
@@ -1 +1,242 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
/* NOTE: Do not edit directly! This file is generated using `npm run update-types` in https://github.com/node-red/nr-monaco-build */
|
|
3
|
+
|
|
4
|
+
declare module 'os' {
|
|
5
|
+
interface CpuInfo {
|
|
6
|
+
model: string;
|
|
7
|
+
speed: number;
|
|
8
|
+
times: {
|
|
9
|
+
user: number;
|
|
10
|
+
nice: number;
|
|
11
|
+
sys: number;
|
|
12
|
+
idle: number;
|
|
13
|
+
irq: number;
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
interface NetworkInterfaceBase {
|
|
18
|
+
address: string;
|
|
19
|
+
netmask: string;
|
|
20
|
+
mac: string;
|
|
21
|
+
internal: boolean;
|
|
22
|
+
cidr: string | null;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
interface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {
|
|
26
|
+
family: "IPv4";
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
interface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {
|
|
30
|
+
family: "IPv6";
|
|
31
|
+
scopeid: number;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
interface UserInfo<T> {
|
|
35
|
+
username: T;
|
|
36
|
+
uid: number;
|
|
37
|
+
gid: number;
|
|
38
|
+
shell: T;
|
|
39
|
+
homedir: T;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
type NetworkInterfaceInfo = NetworkInterfaceInfoIPv4 | NetworkInterfaceInfoIPv6;
|
|
43
|
+
|
|
44
|
+
function hostname(): string;
|
|
45
|
+
function loadavg(): number[];
|
|
46
|
+
function uptime(): number;
|
|
47
|
+
function freemem(): number;
|
|
48
|
+
function totalmem(): number;
|
|
49
|
+
function cpus(): CpuInfo[];
|
|
50
|
+
function type(): string;
|
|
51
|
+
function release(): string;
|
|
52
|
+
function networkInterfaces(): NodeJS.Dict<NetworkInterfaceInfo[]>;
|
|
53
|
+
function homedir(): string;
|
|
54
|
+
function userInfo(options: { encoding: 'buffer' }): UserInfo<Buffer>;
|
|
55
|
+
function userInfo(options?: { encoding: BufferEncoding }): UserInfo<string>;
|
|
56
|
+
|
|
57
|
+
type SignalConstants = {
|
|
58
|
+
[key in NodeJS.Signals]: number;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
namespace constants {
|
|
62
|
+
const UV_UDP_REUSEADDR: number;
|
|
63
|
+
namespace signals {}
|
|
64
|
+
const signals: SignalConstants;
|
|
65
|
+
namespace errno {
|
|
66
|
+
const E2BIG: number;
|
|
67
|
+
const EACCES: number;
|
|
68
|
+
const EADDRINUSE: number;
|
|
69
|
+
const EADDRNOTAVAIL: number;
|
|
70
|
+
const EAFNOSUPPORT: number;
|
|
71
|
+
const EAGAIN: number;
|
|
72
|
+
const EALREADY: number;
|
|
73
|
+
const EBADF: number;
|
|
74
|
+
const EBADMSG: number;
|
|
75
|
+
const EBUSY: number;
|
|
76
|
+
const ECANCELED: number;
|
|
77
|
+
const ECHILD: number;
|
|
78
|
+
const ECONNABORTED: number;
|
|
79
|
+
const ECONNREFUSED: number;
|
|
80
|
+
const ECONNRESET: number;
|
|
81
|
+
const EDEADLK: number;
|
|
82
|
+
const EDESTADDRREQ: number;
|
|
83
|
+
const EDOM: number;
|
|
84
|
+
const EDQUOT: number;
|
|
85
|
+
const EEXIST: number;
|
|
86
|
+
const EFAULT: number;
|
|
87
|
+
const EFBIG: number;
|
|
88
|
+
const EHOSTUNREACH: number;
|
|
89
|
+
const EIDRM: number;
|
|
90
|
+
const EILSEQ: number;
|
|
91
|
+
const EINPROGRESS: number;
|
|
92
|
+
const EINTR: number;
|
|
93
|
+
const EINVAL: number;
|
|
94
|
+
const EIO: number;
|
|
95
|
+
const EISCONN: number;
|
|
96
|
+
const EISDIR: number;
|
|
97
|
+
const ELOOP: number;
|
|
98
|
+
const EMFILE: number;
|
|
99
|
+
const EMLINK: number;
|
|
100
|
+
const EMSGSIZE: number;
|
|
101
|
+
const EMULTIHOP: number;
|
|
102
|
+
const ENAMETOOLONG: number;
|
|
103
|
+
const ENETDOWN: number;
|
|
104
|
+
const ENETRESET: number;
|
|
105
|
+
const ENETUNREACH: number;
|
|
106
|
+
const ENFILE: number;
|
|
107
|
+
const ENOBUFS: number;
|
|
108
|
+
const ENODATA: number;
|
|
109
|
+
const ENODEV: number;
|
|
110
|
+
const ENOENT: number;
|
|
111
|
+
const ENOEXEC: number;
|
|
112
|
+
const ENOLCK: number;
|
|
113
|
+
const ENOLINK: number;
|
|
114
|
+
const ENOMEM: number;
|
|
115
|
+
const ENOMSG: number;
|
|
116
|
+
const ENOPROTOOPT: number;
|
|
117
|
+
const ENOSPC: number;
|
|
118
|
+
const ENOSR: number;
|
|
119
|
+
const ENOSTR: number;
|
|
120
|
+
const ENOSYS: number;
|
|
121
|
+
const ENOTCONN: number;
|
|
122
|
+
const ENOTDIR: number;
|
|
123
|
+
const ENOTEMPTY: number;
|
|
124
|
+
const ENOTSOCK: number;
|
|
125
|
+
const ENOTSUP: number;
|
|
126
|
+
const ENOTTY: number;
|
|
127
|
+
const ENXIO: number;
|
|
128
|
+
const EOPNOTSUPP: number;
|
|
129
|
+
const EOVERFLOW: number;
|
|
130
|
+
const EPERM: number;
|
|
131
|
+
const EPIPE: number;
|
|
132
|
+
const EPROTO: number;
|
|
133
|
+
const EPROTONOSUPPORT: number;
|
|
134
|
+
const EPROTOTYPE: number;
|
|
135
|
+
const ERANGE: number;
|
|
136
|
+
const EROFS: number;
|
|
137
|
+
const ESPIPE: number;
|
|
138
|
+
const ESRCH: number;
|
|
139
|
+
const ESTALE: number;
|
|
140
|
+
const ETIME: number;
|
|
141
|
+
const ETIMEDOUT: number;
|
|
142
|
+
const ETXTBSY: number;
|
|
143
|
+
const EWOULDBLOCK: number;
|
|
144
|
+
const EXDEV: number;
|
|
145
|
+
const WSAEINTR: number;
|
|
146
|
+
const WSAEBADF: number;
|
|
147
|
+
const WSAEACCES: number;
|
|
148
|
+
const WSAEFAULT: number;
|
|
149
|
+
const WSAEINVAL: number;
|
|
150
|
+
const WSAEMFILE: number;
|
|
151
|
+
const WSAEWOULDBLOCK: number;
|
|
152
|
+
const WSAEINPROGRESS: number;
|
|
153
|
+
const WSAEALREADY: number;
|
|
154
|
+
const WSAENOTSOCK: number;
|
|
155
|
+
const WSAEDESTADDRREQ: number;
|
|
156
|
+
const WSAEMSGSIZE: number;
|
|
157
|
+
const WSAEPROTOTYPE: number;
|
|
158
|
+
const WSAENOPROTOOPT: number;
|
|
159
|
+
const WSAEPROTONOSUPPORT: number;
|
|
160
|
+
const WSAESOCKTNOSUPPORT: number;
|
|
161
|
+
const WSAEOPNOTSUPP: number;
|
|
162
|
+
const WSAEPFNOSUPPORT: number;
|
|
163
|
+
const WSAEAFNOSUPPORT: number;
|
|
164
|
+
const WSAEADDRINUSE: number;
|
|
165
|
+
const WSAEADDRNOTAVAIL: number;
|
|
166
|
+
const WSAENETDOWN: number;
|
|
167
|
+
const WSAENETUNREACH: number;
|
|
168
|
+
const WSAENETRESET: number;
|
|
169
|
+
const WSAECONNABORTED: number;
|
|
170
|
+
const WSAECONNRESET: number;
|
|
171
|
+
const WSAENOBUFS: number;
|
|
172
|
+
const WSAEISCONN: number;
|
|
173
|
+
const WSAENOTCONN: number;
|
|
174
|
+
const WSAESHUTDOWN: number;
|
|
175
|
+
const WSAETOOMANYREFS: number;
|
|
176
|
+
const WSAETIMEDOUT: number;
|
|
177
|
+
const WSAECONNREFUSED: number;
|
|
178
|
+
const WSAELOOP: number;
|
|
179
|
+
const WSAENAMETOOLONG: number;
|
|
180
|
+
const WSAEHOSTDOWN: number;
|
|
181
|
+
const WSAEHOSTUNREACH: number;
|
|
182
|
+
const WSAENOTEMPTY: number;
|
|
183
|
+
const WSAEPROCLIM: number;
|
|
184
|
+
const WSAEUSERS: number;
|
|
185
|
+
const WSAEDQUOT: number;
|
|
186
|
+
const WSAESTALE: number;
|
|
187
|
+
const WSAEREMOTE: number;
|
|
188
|
+
const WSASYSNOTREADY: number;
|
|
189
|
+
const WSAVERNOTSUPPORTED: number;
|
|
190
|
+
const WSANOTINITIALISED: number;
|
|
191
|
+
const WSAEDISCON: number;
|
|
192
|
+
const WSAENOMORE: number;
|
|
193
|
+
const WSAECANCELLED: number;
|
|
194
|
+
const WSAEINVALIDPROCTABLE: number;
|
|
195
|
+
const WSAEINVALIDPROVIDER: number;
|
|
196
|
+
const WSAEPROVIDERFAILEDINIT: number;
|
|
197
|
+
const WSASYSCALLFAILURE: number;
|
|
198
|
+
const WSASERVICE_NOT_FOUND: number;
|
|
199
|
+
const WSATYPE_NOT_FOUND: number;
|
|
200
|
+
const WSA_E_NO_MORE: number;
|
|
201
|
+
const WSA_E_CANCELLED: number;
|
|
202
|
+
const WSAEREFUSED: number;
|
|
203
|
+
}
|
|
204
|
+
namespace priority {
|
|
205
|
+
const PRIORITY_LOW: number;
|
|
206
|
+
const PRIORITY_BELOW_NORMAL: number;
|
|
207
|
+
const PRIORITY_NORMAL: number;
|
|
208
|
+
const PRIORITY_ABOVE_NORMAL: number;
|
|
209
|
+
const PRIORITY_HIGH: number;
|
|
210
|
+
const PRIORITY_HIGHEST: number;
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
function arch(): string;
|
|
215
|
+
/**
|
|
216
|
+
* Returns a string identifying the kernel version.
|
|
217
|
+
* On POSIX systems, the operating system release is determined by calling
|
|
218
|
+
* [uname(3)][]. On Windows, `pRtlGetVersion` is used, and if it is not available,
|
|
219
|
+
* `GetVersionExW()` will be used. See
|
|
220
|
+
* https://en.wikipedia.org/wiki/Uname#Examples for more information.
|
|
221
|
+
*/
|
|
222
|
+
function version(): string;
|
|
223
|
+
function platform(): NodeJS.Platform;
|
|
224
|
+
function tmpdir(): string;
|
|
225
|
+
const EOL: string;
|
|
226
|
+
function endianness(): "BE" | "LE";
|
|
227
|
+
/**
|
|
228
|
+
* Gets the priority of a process.
|
|
229
|
+
* Defaults to current process.
|
|
230
|
+
*/
|
|
231
|
+
function getPriority(pid?: number): number;
|
|
232
|
+
/**
|
|
233
|
+
* Sets the priority of the current process.
|
|
234
|
+
* @param priority Must be in range of -20 to 19
|
|
235
|
+
*/
|
|
236
|
+
function setPriority(priority: number): void;
|
|
237
|
+
/**
|
|
238
|
+
* Sets the priority of the process specified process.
|
|
239
|
+
* @param priority Must be in range of -20 to 19
|
|
240
|
+
*/
|
|
241
|
+
function setPriority(pid: number, priority: number): void;
|
|
242
|
+
}
|
|
@@ -1 +1,156 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
/* NOTE: Do not edit directly! This file is generated using `npm run update-types` in https://github.com/node-red/nr-monaco-build */
|
|
3
|
+
|
|
4
|
+
declare module 'path' {
|
|
5
|
+
namespace path {
|
|
6
|
+
/**
|
|
7
|
+
* A parsed path object generated by path.parse() or consumed by path.format().
|
|
8
|
+
*/
|
|
9
|
+
interface ParsedPath {
|
|
10
|
+
/**
|
|
11
|
+
* The root of the path such as '/' or 'c:\'
|
|
12
|
+
*/
|
|
13
|
+
root: string;
|
|
14
|
+
/**
|
|
15
|
+
* The full directory path such as '/home/user/dir' or 'c:\path\dir'
|
|
16
|
+
*/
|
|
17
|
+
dir: string;
|
|
18
|
+
/**
|
|
19
|
+
* The file name including extension (if any) such as 'index.html'
|
|
20
|
+
*/
|
|
21
|
+
base: string;
|
|
22
|
+
/**
|
|
23
|
+
* The file extension (if any) such as '.html'
|
|
24
|
+
*/
|
|
25
|
+
ext: string;
|
|
26
|
+
/**
|
|
27
|
+
* The file name without extension (if any) such as 'index'
|
|
28
|
+
*/
|
|
29
|
+
name: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
interface FormatInputPathObject {
|
|
33
|
+
/**
|
|
34
|
+
* The root of the path such as '/' or 'c:\'
|
|
35
|
+
*/
|
|
36
|
+
root?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* The full directory path such as '/home/user/dir' or 'c:\path\dir'
|
|
39
|
+
*/
|
|
40
|
+
dir?: string | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* The file name including extension (if any) such as 'index.html'
|
|
43
|
+
*/
|
|
44
|
+
base?: string | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* The file extension (if any) such as '.html'
|
|
47
|
+
*/
|
|
48
|
+
ext?: string | undefined;
|
|
49
|
+
/**
|
|
50
|
+
* The file name without extension (if any) such as 'index'
|
|
51
|
+
*/
|
|
52
|
+
name?: string | undefined;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
interface PlatformPath {
|
|
56
|
+
/**
|
|
57
|
+
* Normalize a string path, reducing '..' and '.' parts.
|
|
58
|
+
* When multiple slashes are found, they're replaced by a single one; when the path contains a trailing slash, it is preserved. On Windows backslashes are used.
|
|
59
|
+
*
|
|
60
|
+
* @param p string path to normalize.
|
|
61
|
+
*/
|
|
62
|
+
normalize(p: string): string;
|
|
63
|
+
/**
|
|
64
|
+
* Join all arguments together and normalize the resulting path.
|
|
65
|
+
* Arguments must be strings. In v0.8, non-string arguments were silently ignored. In v0.10 and up, an exception is thrown.
|
|
66
|
+
*
|
|
67
|
+
* @param paths paths to join.
|
|
68
|
+
*/
|
|
69
|
+
join(...paths: string[]): string;
|
|
70
|
+
/**
|
|
71
|
+
* The right-most parameter is considered {to}. Other parameters are considered an array of {from}.
|
|
72
|
+
*
|
|
73
|
+
* Starting from leftmost {from} parameter, resolves {to} to an absolute path.
|
|
74
|
+
*
|
|
75
|
+
* If {to} isn't already absolute, {from} arguments are prepended in right to left order,
|
|
76
|
+
* until an absolute path is found. If after using all {from} paths still no absolute path is found,
|
|
77
|
+
* the current working directory is used as well. The resulting path is normalized,
|
|
78
|
+
* and trailing slashes are removed unless the path gets resolved to the root directory.
|
|
79
|
+
*
|
|
80
|
+
* @param pathSegments string paths to join. Non-string arguments are ignored.
|
|
81
|
+
*/
|
|
82
|
+
resolve(...pathSegments: string[]): string;
|
|
83
|
+
/**
|
|
84
|
+
* Determines whether {path} is an absolute path. An absolute path will always resolve to the same location, regardless of the working directory.
|
|
85
|
+
*
|
|
86
|
+
* @param path path to test.
|
|
87
|
+
*/
|
|
88
|
+
isAbsolute(p: string): boolean;
|
|
89
|
+
/**
|
|
90
|
+
* Solve the relative path from {from} to {to}.
|
|
91
|
+
* At times we have two absolute paths, and we need to derive the relative path from one to the other. This is actually the reverse transform of path.resolve.
|
|
92
|
+
*/
|
|
93
|
+
relative(from: string, to: string): string;
|
|
94
|
+
/**
|
|
95
|
+
* Return the directory name of a path. Similar to the Unix dirname command.
|
|
96
|
+
*
|
|
97
|
+
* @param p the path to evaluate.
|
|
98
|
+
*/
|
|
99
|
+
dirname(p: string): string;
|
|
100
|
+
/**
|
|
101
|
+
* Return the last portion of a path. Similar to the Unix basename command.
|
|
102
|
+
* Often used to extract the file name from a fully qualified path.
|
|
103
|
+
*
|
|
104
|
+
* @param p the path to evaluate.
|
|
105
|
+
* @param ext optionally, an extension to remove from the result.
|
|
106
|
+
*/
|
|
107
|
+
basename(p: string, ext?: string): string;
|
|
108
|
+
/**
|
|
109
|
+
* Return the extension of the path, from the last '.' to end of string in the last portion of the path.
|
|
110
|
+
* If there is no '.' in the last portion of the path or the first character of it is '.', then it returns an empty string
|
|
111
|
+
*
|
|
112
|
+
* @param p the path to evaluate.
|
|
113
|
+
*/
|
|
114
|
+
extname(p: string): string;
|
|
115
|
+
/**
|
|
116
|
+
* The platform-specific file separator. '\\' or '/'.
|
|
117
|
+
*/
|
|
118
|
+
readonly sep: string;
|
|
119
|
+
/**
|
|
120
|
+
* The platform-specific file delimiter. ';' or ':'.
|
|
121
|
+
*/
|
|
122
|
+
readonly delimiter: string;
|
|
123
|
+
/**
|
|
124
|
+
* Returns an object from a path string - the opposite of format().
|
|
125
|
+
*
|
|
126
|
+
* @param pathString path to evaluate.
|
|
127
|
+
*/
|
|
128
|
+
parse(p: string): ParsedPath;
|
|
129
|
+
/**
|
|
130
|
+
* Returns a path string from an object - the opposite of parse().
|
|
131
|
+
*
|
|
132
|
+
* @param pathString path to evaluate.
|
|
133
|
+
*/
|
|
134
|
+
format(pP: FormatInputPathObject): string;
|
|
135
|
+
/**
|
|
136
|
+
* On Windows systems only, returns an equivalent namespace-prefixed path for the given path.
|
|
137
|
+
* If path is not a string, path will be returned without modifications.
|
|
138
|
+
* This method is meaningful only on Windows system.
|
|
139
|
+
* On POSIX systems, the method is non-operational and always returns path without modifications.
|
|
140
|
+
*/
|
|
141
|
+
toNamespacedPath(path: string): string;
|
|
142
|
+
/**
|
|
143
|
+
* Posix specific pathing.
|
|
144
|
+
* Same as parent object on posix.
|
|
145
|
+
*/
|
|
146
|
+
readonly posix: PlatformPath;
|
|
147
|
+
/**
|
|
148
|
+
* Windows specific pathing.
|
|
149
|
+
* Same as parent object on windows
|
|
150
|
+
*/
|
|
151
|
+
readonly win32: PlatformPath;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
const path: path.PlatformPath;
|
|
155
|
+
export = path;
|
|
156
|
+
}
|
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
|
|
2
|
+
/* NOTE: Do not edit directly! This file is generated using `npm run update-types` in https://github.com/node-red/nr-monaco-build */
|
|
3
|
+
|
|
4
|
+
declare module 'perf_hooks' {
|
|
5
|
+
import { AsyncResource } from 'async_hooks';
|
|
6
|
+
|
|
7
|
+
type EntryType = 'node' | 'mark' | 'measure' | 'gc' | 'function' | 'http2' | 'http';
|
|
8
|
+
|
|
9
|
+
interface PerformanceEntry {
|
|
10
|
+
/**
|
|
11
|
+
* The total number of milliseconds elapsed for this entry.
|
|
12
|
+
* This value will not be meaningful for all Performance Entry types.
|
|
13
|
+
*/
|
|
14
|
+
readonly duration: number;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* The name of the performance entry.
|
|
18
|
+
*/
|
|
19
|
+
readonly name: string;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* The high resolution millisecond timestamp marking the starting time of the Performance Entry.
|
|
23
|
+
*/
|
|
24
|
+
readonly startTime: number;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* The type of the performance entry.
|
|
28
|
+
* Currently it may be one of: 'node', 'mark', 'measure', 'gc', or 'function'.
|
|
29
|
+
*/
|
|
30
|
+
readonly entryType: EntryType;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* When `performanceEntry.entryType` is equal to 'gc', `the performance.kind` property identifies
|
|
34
|
+
* the type of garbage collection operation that occurred.
|
|
35
|
+
* See perf_hooks.constants for valid values.
|
|
36
|
+
*/
|
|
37
|
+
readonly kind?: number | undefined;
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* When `performanceEntry.entryType` is equal to 'gc', the `performance.flags`
|
|
41
|
+
* property contains additional information about garbage collection operation.
|
|
42
|
+
* See perf_hooks.constants for valid values.
|
|
43
|
+
*/
|
|
44
|
+
readonly flags?: number | undefined;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
interface PerformanceNodeTiming extends PerformanceEntry {
|
|
48
|
+
/**
|
|
49
|
+
* The high resolution millisecond timestamp at which the Node.js process completed bootstrap.
|
|
50
|
+
*/
|
|
51
|
+
readonly bootstrapComplete: number;
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* The high resolution millisecond timestamp at which the Node.js process completed bootstrapping.
|
|
55
|
+
* If bootstrapping has not yet finished, the property has the value of -1.
|
|
56
|
+
*/
|
|
57
|
+
readonly environment: number;
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* The high resolution millisecond timestamp at which the Node.js environment was initialized.
|
|
61
|
+
*/
|
|
62
|
+
readonly idleTime: number;
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* The high resolution millisecond timestamp of the amount of time the event loop has been idle
|
|
66
|
+
* within the event loop's event provider (e.g. `epoll_wait`). This does not take CPU usage
|
|
67
|
+
* into consideration. If the event loop has not yet started (e.g., in the first tick of the main script),
|
|
68
|
+
* the property has the value of 0.
|
|
69
|
+
*/
|
|
70
|
+
readonly loopExit: number;
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* The high resolution millisecond timestamp at which the Node.js event loop started.
|
|
74
|
+
* If the event loop has not yet started (e.g., in the first tick of the main script), the property has the value of -1.
|
|
75
|
+
*/
|
|
76
|
+
readonly loopStart: number;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* The high resolution millisecond timestamp at which the V8 platform was initialized.
|
|
80
|
+
*/
|
|
81
|
+
readonly v8Start: number;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
interface EventLoopUtilization {
|
|
85
|
+
idle: number;
|
|
86
|
+
active: number;
|
|
87
|
+
utilization: number;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
interface Performance {
|
|
91
|
+
/**
|
|
92
|
+
* If name is not provided, removes all PerformanceMark objects from the Performance Timeline.
|
|
93
|
+
* If name is provided, removes only the named mark.
|
|
94
|
+
* @param name
|
|
95
|
+
*/
|
|
96
|
+
clearMarks(name?: string): void;
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* Creates a new PerformanceMark entry in the Performance Timeline.
|
|
100
|
+
* A PerformanceMark is a subclass of PerformanceEntry whose performanceEntry.entryType is always 'mark',
|
|
101
|
+
* and whose performanceEntry.duration is always 0.
|
|
102
|
+
* Performance marks are used to mark specific significant moments in the Performance Timeline.
|
|
103
|
+
* @param name
|
|
104
|
+
*/
|
|
105
|
+
mark(name?: string): void;
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* Creates a new PerformanceMeasure entry in the Performance Timeline.
|
|
109
|
+
* A PerformanceMeasure is a subclass of PerformanceEntry whose performanceEntry.entryType is always 'measure',
|
|
110
|
+
* and whose performanceEntry.duration measures the number of milliseconds elapsed since startMark and endMark.
|
|
111
|
+
*
|
|
112
|
+
* The startMark argument may identify any existing PerformanceMark in the the Performance Timeline, or may identify
|
|
113
|
+
* any of the timestamp properties provided by the PerformanceNodeTiming class. If the named startMark does not exist,
|
|
114
|
+
* then startMark is set to timeOrigin by default.
|
|
115
|
+
*
|
|
116
|
+
* The endMark argument must identify any existing PerformanceMark in the the Performance Timeline or any of the timestamp
|
|
117
|
+
* properties provided by the PerformanceNodeTiming class. If the named endMark does not exist, an error will be thrown.
|
|
118
|
+
* @param name
|
|
119
|
+
* @param startMark
|
|
120
|
+
* @param endMark
|
|
121
|
+
*/
|
|
122
|
+
measure(name: string, startMark?: string, endMark?: string): void;
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* An instance of the PerformanceNodeTiming class that provides performance metrics for specific Node.js operational milestones.
|
|
126
|
+
*/
|
|
127
|
+
readonly nodeTiming: PerformanceNodeTiming;
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* @return the current high resolution millisecond timestamp
|
|
131
|
+
*/
|
|
132
|
+
now(): number;
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* The timeOrigin specifies the high resolution millisecond timestamp from which all performance metric durations are measured.
|
|
136
|
+
*/
|
|
137
|
+
readonly timeOrigin: number;
|
|
138
|
+
|
|
139
|
+
/**
|
|
140
|
+
* Wraps a function within a new function that measures the running time of the wrapped function.
|
|
141
|
+
* A PerformanceObserver must be subscribed to the 'function' event type in order for the timing details to be accessed.
|
|
142
|
+
* @param fn
|
|
143
|
+
*/
|
|
144
|
+
timerify<T extends (...optionalParams: any[]) => any>(fn: T): T;
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* eventLoopUtilization is similar to CPU utilization except that it is calculated using high precision wall-clock time.
|
|
148
|
+
* It represents the percentage of time the event loop has spent outside the event loop's event provider (e.g. epoll_wait).
|
|
149
|
+
* No other CPU idle time is taken into consideration.
|
|
150
|
+
*
|
|
151
|
+
* @param util1 The result of a previous call to eventLoopUtilization()
|
|
152
|
+
* @param util2 The result of a previous call to eventLoopUtilization() prior to util1
|
|
153
|
+
*/
|
|
154
|
+
eventLoopUtilization(util1?: EventLoopUtilization, util2?: EventLoopUtilization): EventLoopUtilization;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
interface PerformanceObserverEntryList {
|
|
158
|
+
/**
|
|
159
|
+
* @return a list of PerformanceEntry objects in chronological order with respect to performanceEntry.startTime.
|
|
160
|
+
*/
|
|
161
|
+
getEntries(): PerformanceEntry[];
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* @return a list of PerformanceEntry objects in chronological order with respect to performanceEntry.startTime
|
|
165
|
+
* whose performanceEntry.name is equal to name, and optionally, whose performanceEntry.entryType is equal to type.
|
|
166
|
+
*/
|
|
167
|
+
getEntriesByName(name: string, type?: EntryType): PerformanceEntry[];
|
|
168
|
+
|
|
169
|
+
/**
|
|
170
|
+
* @return Returns a list of PerformanceEntry objects in chronological order with respect to performanceEntry.startTime
|
|
171
|
+
* whose performanceEntry.entryType is equal to type.
|
|
172
|
+
*/
|
|
173
|
+
getEntriesByType(type: EntryType): PerformanceEntry[];
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
type PerformanceObserverCallback = (list: PerformanceObserverEntryList, observer: PerformanceObserver) => void;
|
|
177
|
+
|
|
178
|
+
class PerformanceObserver extends AsyncResource {
|
|
179
|
+
constructor(callback: PerformanceObserverCallback);
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Disconnects the PerformanceObserver instance from all notifications.
|
|
183
|
+
*/
|
|
184
|
+
disconnect(): void;
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Subscribes the PerformanceObserver instance to notifications of new PerformanceEntry instances identified by options.entryTypes.
|
|
188
|
+
* When options.buffered is false, the callback will be invoked once for every PerformanceEntry instance.
|
|
189
|
+
* Property buffered defaults to false.
|
|
190
|
+
* @param options
|
|
191
|
+
*/
|
|
192
|
+
observe(options: { entryTypes: ReadonlyArray<EntryType>; buffered?: boolean | undefined }): void;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
namespace constants {
|
|
196
|
+
const NODE_PERFORMANCE_GC_MAJOR: number;
|
|
197
|
+
const NODE_PERFORMANCE_GC_MINOR: number;
|
|
198
|
+
const NODE_PERFORMANCE_GC_INCREMENTAL: number;
|
|
199
|
+
const NODE_PERFORMANCE_GC_WEAKCB: number;
|
|
200
|
+
|
|
201
|
+
const NODE_PERFORMANCE_GC_FLAGS_NO: number;
|
|
202
|
+
const NODE_PERFORMANCE_GC_FLAGS_CONSTRUCT_RETAINED: number;
|
|
203
|
+
const NODE_PERFORMANCE_GC_FLAGS_FORCED: number;
|
|
204
|
+
const NODE_PERFORMANCE_GC_FLAGS_SYNCHRONOUS_PHANTOM_PROCESSING: number;
|
|
205
|
+
const NODE_PERFORMANCE_GC_FLAGS_ALL_AVAILABLE_GARBAGE: number;
|
|
206
|
+
const NODE_PERFORMANCE_GC_FLAGS_ALL_EXTERNAL_MEMORY: number;
|
|
207
|
+
const NODE_PERFORMANCE_GC_FLAGS_SCHEDULE_IDLE: number;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
const performance: Performance;
|
|
211
|
+
|
|
212
|
+
interface EventLoopMonitorOptions {
|
|
213
|
+
/**
|
|
214
|
+
* The sampling rate in milliseconds.
|
|
215
|
+
* Must be greater than zero.
|
|
216
|
+
* @default 10
|
|
217
|
+
*/
|
|
218
|
+
resolution?: number | undefined;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
interface EventLoopDelayMonitor {
|
|
222
|
+
/**
|
|
223
|
+
* Enables the event loop delay sample timer. Returns `true` if the timer was started, `false` if it was already started.
|
|
224
|
+
*/
|
|
225
|
+
enable(): boolean;
|
|
226
|
+
/**
|
|
227
|
+
* Disables the event loop delay sample timer. Returns `true` if the timer was stopped, `false` if it was already stopped.
|
|
228
|
+
*/
|
|
229
|
+
disable(): boolean;
|
|
230
|
+
|
|
231
|
+
/**
|
|
232
|
+
* Resets the collected histogram data.
|
|
233
|
+
*/
|
|
234
|
+
reset(): void;
|
|
235
|
+
|
|
236
|
+
/**
|
|
237
|
+
* Returns the value at the given percentile.
|
|
238
|
+
* @param percentile A percentile value between 1 and 100.
|
|
239
|
+
*/
|
|
240
|
+
percentile(percentile: number): number;
|
|
241
|
+
|
|
242
|
+
/**
|
|
243
|
+
* A `Map` object detailing the accumulated percentile distribution.
|
|
244
|
+
*/
|
|
245
|
+
readonly percentiles: Map<number, number>;
|
|
246
|
+
|
|
247
|
+
/**
|
|
248
|
+
* The number of times the event loop delay exceeded the maximum 1 hour eventloop delay threshold.
|
|
249
|
+
*/
|
|
250
|
+
readonly exceeds: number;
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* The minimum recorded event loop delay.
|
|
254
|
+
*/
|
|
255
|
+
readonly min: number;
|
|
256
|
+
|
|
257
|
+
/**
|
|
258
|
+
* The maximum recorded event loop delay.
|
|
259
|
+
*/
|
|
260
|
+
readonly max: number;
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* The mean of the recorded event loop delays.
|
|
264
|
+
*/
|
|
265
|
+
readonly mean: number;
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* The standard deviation of the recorded event loop delays.
|
|
269
|
+
*/
|
|
270
|
+
readonly stddev: number;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
function monitorEventLoopDelay(options?: EventLoopMonitorOptions): EventLoopDelayMonitor;
|
|
274
|
+
}
|