2019-12-25 12:01:12 +02:00
|
|
|
import { Resp as TResp } from './request';
|
|
|
|
import { Middleware as TMiddleware } from './PromiseMiddlewareLayer';
|
|
|
|
|
|
|
|
export { default } from './request';
|
2017-08-01 23:00:02 +03:00
|
|
|
export { default as InternalServerError } from './InternalServerError';
|
2018-11-04 10:09:42 +02:00
|
|
|
export { default as RequestAbortedError } from './RequestAbortedError';
|
2016-07-30 21:18:58 +03:00
|
|
|
|
2019-12-25 12:01:12 +02:00
|
|
|
export type Resp<T> = TResp<T>;
|
|
|
|
export type Middleware = TMiddleware;
|
|
|
|
|
2017-08-07 23:11:39 +03:00
|
|
|
/**
|
2019-12-25 12:01:12 +02:00
|
|
|
* Usage: Query<'required'|'keys'|'names'>
|
2017-08-07 23:11:39 +03:00
|
|
|
* TODO: find a way to make it more friendly with URLSearchParams type
|
|
|
|
*/
|
2019-12-07 13:28:52 +02:00
|
|
|
export type Query<T extends string> = {
|
2020-05-24 02:08:24 +03:00
|
|
|
get: (key: T) => string | void;
|
|
|
|
set: (key: T, value: any) => void;
|
2017-08-07 23:11:39 +03:00
|
|
|
};
|