-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathresolve-result.ts
More file actions
42 lines (37 loc) · 927 Bytes
/
resolve-result.ts
File metadata and controls
42 lines (37 loc) · 927 Bytes
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
/**
* @file Hooks - ResolveHookResult
* @module esm-types/hooks/ResolveHookResult
*/
import type { Format } from '#src/enums'
import type { ResolvedModuleUrl } from '#src/types'
import type { Nilable } from '@flex-development/tutils'
/**
* [`resolve`][1] hook result.
*
* [1]: https://nodejs.org/api/esm.html#resolvespecifier-context-nextresolve
*/
interface ResolveHookResult {
/**
* Module format hint for [`load`][1] hook.
*
* **Note**: Hint may be ignored.
*
* [1]: https://nodejs.org/api/esm.html#loadurl-context-nextload
*
* @see {@linkcode Format}
*/
format?: Nilable<Format>
/**
* Signal that the current hook terminates the chain of `resolve` hooks.
*
* @default false
*/
shortCircuit?: boolean | undefined
/**
* Resolved module URL.
*
* @see {@linkcode ResolvedModuleUrl}
*/
url: ResolvedModuleUrl
}
export type { ResolveHookResult as default }