export declare function request(props: RequestProps): hyperappSubset.Effect; type RequestProps = JsonRequestProps | TextRequestProps | FormDataRequestProps | BlobRequestProps | ArrayBufferRequestProps; interface RequestPropsBase { url: Parameters[0]; options?: Parameters[1]; } interface JsonRequestProps extends RequestPropsBase { expect?: 'json'; action: hyperappSubset.Dispatchable; } interface TextRequestProps extends RequestPropsBase { expect: 'text'; action: hyperappSubset.Dispatchable; } interface FormDataRequestProps extends RequestPropsBase { expect: 'formData'; action: hyperappSubset.Dispatchable; } interface BlobRequestProps extends RequestPropsBase { expect: 'blob'; action: hyperappSubset.Dispatchable; } interface ArrayBufferRequestProps extends RequestPropsBase { expect: 'arrayBuffer'; action: hyperappSubset.Dispatchable; } declare namespace hyperappSubset { type AnyState = boolean | string | number | object | symbol | null | undefined; type PayloadCreator = ((data: DPayload) => CPayload); type Dispatchable = ( State | [State, ...Effect[]] | ([Action, PayloadCreator]) | ([Action, CPayload]) | Action // (state) => ({ ... }) | (state) => ([{ ... }, effect1, ...]) | Action // (state, data) => ({ ... }) | (state, data) => ([{ ... }, effect1, ...]) ); type Dispatch = (obj: Dispatchable, data: NextPayload) => State; interface EffectRunner { (dispatch: Dispatch, props: Props): void; } type Effect = [EffectRunner, any] | [EffectRunner]; interface SubscriptionRunner { (dispatch: Dispatch, props: Props): (() => void); } type Subscription = [SubscriptionRunner, any] | [SubscriptionRunner]; interface Action { (state: State, data: Payload): Dispatchable; } }