You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* The map field may be either a string or the parsed JSON object (i.e.,
15
-
* it must be a valid argument to the SourceMapConsumer constructor).
13
+
* Output of `retrieveSourceMap()`.
14
+
* The map field may be either a string or the parsed JSON object (i.e.,
15
+
* it must be a valid argument to the SourceMapConsumer constructor).
16
16
*/
17
17
exportinterfaceUrlAndMap{
18
-
url: string;
18
+
url?: string|undefined;
19
19
map: string|RawSourceMap;
20
20
}
21
21
22
+
exporttypeEnvironment='auto'|'browser'|'node';
23
+
22
24
/**
23
25
* Options to install().
24
26
*/
25
27
exportinterfaceOptions{
28
+
/**
29
+
* This module installs two things: a change to the `stack` property on `Error`
30
+
* objects and a handler for uncaught exceptions that mimics node's default exception
31
+
* handler (the handler can be seen in the demos below). You may want to disable the
32
+
* handler if you have your own uncaught exception handler. This can be done by passing
33
+
* an argument to the installer.
34
+
*
35
+
* @example
36
+
* import { install } from 'source-map-support';
37
+
*
38
+
* install({
39
+
* handleUncaughtExceptions: false
40
+
* });
41
+
*/
26
42
handleUncaughtExceptions?: boolean|undefined;
43
+
/**
44
+
* To support files with inline source maps, the `hookRequire` options can be specified,
45
+
* which will monitor all source files for inline source maps.
46
+
*
47
+
* This monkey patches the `require` module loading chain, so is not enabled by default
48
+
* and is not recommended for any sort of production usage.
49
+
*
50
+
* @example
51
+
* import { install } from 'source-map-support';
52
+
*
53
+
* install({
54
+
* hookRequire: true
55
+
* });
56
+
* ```
57
+
*/
27
58
hookRequire?: boolean|undefined;
59
+
/**
60
+
* If `true`, the caches are reset before a stack trace formatting operation.
61
+
*/
28
62
emptyCacheBetweenOperations?: boolean|undefined;
29
-
environment?: 'auto'|'browser'|'node'|undefined;
63
+
/**
64
+
* The module will by default assume a browser environment if `XMLHttpRequest` and `window`
65
+
* are defined. If either of these do not exist it will instead assume a node environment.
66
+
* In some rare cases, e.g. when running a browser emulation and where both variables are
67
+
* also set, you can explicitly specify the environment to be either `'browser'` or `'node'`.
68
+
*
69
+
* @example
70
+
* import { install } from 'source-map-support';
71
+
*
72
+
* install({
73
+
* environment: 'node'
74
+
* });
75
+
*/
76
+
environment?: Environment|undefined;
77
+
/**
78
+
* Disable all other means of retrieving file contents and use only the provided
79
+
* `retrieveFile` handler.
80
+
*/
30
81
overrideRetrieveFile?: boolean|undefined;
82
+
/**
83
+
* Disable all other means of retrieving source maps and use only the provided
84
+
* `retrieveSourceMap` handler.
85
+
*/
31
86
overrideRetrieveSourceMap?: boolean|undefined;
32
-
retrieveFile?(path: string): string;
87
+
/**
88
+
* Allow sources to be found by methods other than reading the files
89
+
* directly from disk.
90
+
*/
91
+
retrieveFile?(path: string): string|null;
92
+
/**
93
+
* This module loads source maps from the filesystem by default. You can provide alternate
94
+
* loading behavior through a callback as shown below. For example, [Meteor](https://github.com/meteor)
95
+
* keeps all source maps cached in memory to avoid disk access.
0 commit comments