Skip to content

Commit e3c714e

Browse files
committed
fix: improve types of loader context
1 parent fd73275 commit e3c714e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/types/mkdist.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
// TODO: export from mkdist
22

3+
import type { MkdistOptions } from 'mkdist'
4+
35
export interface InputFile {
46
path: string
57
extension: string
@@ -25,6 +27,7 @@ export type LoaderResult = OutputFile[] | undefined
2527

2628
export interface LoaderContext {
2729
loadFile: (input: InputFile) => LoaderResult | Promise<LoaderResult>
30+
options: MkdistOptions
2831
}
2932

3033
export type Loader = (input: InputFile, context: LoaderContext) => LoaderResult | Promise<LoaderResult>

0 commit comments

Comments
 (0)