import { ResourceLoader, ResourceLoaderConstructorOptions, FetchOptions, AbortablePromise } from 'jsdom';

type Matcher = string | RegExp;

type NewOptions = {
    whitelist: Matcher[];
} | {
    blacklist: Matcher[];
} | {
    whitelist: Matcher[];
    blacklist: Matcher[];
};
type ConfigurableResourceLoaderOptions = ResourceLoaderConstructorOptions & NewOptions;
declare class ConfigurableResourceLoader extends ResourceLoader {
    options: ConfigurableResourceLoaderOptions;
    constructor(options?: ConfigurableResourceLoaderOptions);
    private static strictlyResourceLoaderConstructorOptions;
    fetch(url: string, options: FetchOptions): AbortablePromise<Buffer> | null;
}

export { ConfigurableResourceLoader, type ConfigurableResourceLoaderOptions, type Matcher };
