UNPKG

@pipepack/enhanced-resolver

Version:

yet, reimplement enhanced-resolve with the idea 'simple is best'.

31 lines (30 loc) 862 B
import { Channel } from '../utils/constant'; import type { FileSystem } from './fs'; export interface Material { context: string; referencePath: string; issuer?: string; } export interface ReferencePathNormal { channel: Channel; referencePathName: string; referencePathQuery: string; referencePathFragment: string; } export interface ReferencePathNode { referenceModuleName: string; referenceModuleSubpath: string; } export declare type NormalRequest = Material & ReferencePathNormal; export interface NormalTerminal extends NormalRequest { absPath: string; } export interface RelativeResolverOptions { fs: FileSystem; extensions: string[]; modules: string[]; mainFields: string[]; mainFiles: string[]; descriptionFiles: string[]; } export declare type ModuleDescription = Record<string, unknown>;