improvement - EffectResponse as interface
MODIFY
src/effects/effects.interface.ts
src/effects/effects.interface.ts
@@ -2,11 +2,11 @@ import { Observable } from 'rxjs';
import { HttpRequest, HttpResponse } from '../http.interface';
import { StatusCode } from '../util';
-export type EffectResponse = {
- status: StatusCode,
- body?: object,
- headers?: Record<string, string>,
-};
+export interface EffectResponse {
+ status: StatusCode;
+ body?: object;
+ headers?: Record<string, string>;
+}
export type Effect<T = EffectResponse, U = any> = (
request$: Observable<HttpRequest>,

improvement - EffectResponse as interface