@busymango/fetch-driver
Version:
12 lines (11 loc) • 489 B
TypeScript
import { DriveContext } from './context';
import { ReceiverFunc } from './types';
export type RawTextBodyType = "txt" | "css" | "xml" | "html" | "plain" | "richtext" | "javascript";
/**
* 断言目标值是否为原始文本类型
*/
export declare function isRawTextBody(type?: string): type is RawTextBodyType;
export declare const parser: () => <T>(response: Response, context: DriveContext<T>, params?: {
attchment?: boolean;
receiver?: ReceiverFunc<T>;
}) => Promise<void>;