UNPKG

738 BTypeScriptView Raw
1import type { ResolveOptions } from 'enhanced-resolve';
2export declare const defaultConditionNames: string[];
3export declare const defaultExtensions: string[];
4export declare const defaultExtensionAlias: {
5 '.js': string[];
6 '.jsx': string[];
7 '.cjs': string[];
8 '.mjs': string[];
9};
10export declare const defaultMainFields: string[];
11export declare const interfaceVersion = 2;
12export interface TsResolverOptions extends Omit<ResolveOptions, 'fileSystem' | 'useSyncFileSystemCalls'> {
13 alwaysTryTypes?: boolean;
14 project?: string[] | string;
15 extensions?: string[];
16}
17export declare function resolve(source: string, file: string, options?: TsResolverOptions | null): {
18 found: boolean;
19 path?: string | null;
20};