FetchClient constructor
FetchClient({
- RequestMode mode = RequestMode.noCors,
- RequestCredentials credentials = RequestCredentials.sameOrigin,
- RequestCache cache = RequestCache.byDefault,
- String referrer = '',
- RequestReferrerPolicy referrerPolicy = RequestReferrerPolicy.strictOriginWhenCrossOrigin,
- RedirectPolicy redirectPolicy = RedirectPolicy.alwaysFollow,
- bool streamRequests = false,
Create new HTTP client based on Fetch API.
Implementation
FetchClient({
this.mode = RequestMode.noCors,
this.credentials = RequestCredentials.sameOrigin,
this.cache = RequestCache.byDefault,
this.referrer = '',
this.referrerPolicy = RequestReferrerPolicy.strictOriginWhenCrossOrigin,
this.redirectPolicy = RedirectPolicy.alwaysFollow,
this.streamRequests = false,
});