From a71516e935a1abca67d259930046e80700b824f1 Mon Sep 17 00:00:00 2001 From: Gustavo Rodrigues Date: Wed, 28 Aug 2019 17:05:36 -0300 Subject: [PATCH 1/2] Update fetch() browser support in docs As https://caniuse.com/#feat=fetch shows it's supported since Safari 10.1. --- docs/request.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/request.md b/docs/request.md index 4d4541473..a280d0818 100644 --- a/docs/request.md +++ b/docs/request.md @@ -494,7 +494,7 @@ Mithril's `m.request` uses `XMLHttpRequest` instead of `fetch()` for a number of - `fetch` is not fully standardized yet, and may be subject to specification changes. - `XMLHttpRequest` calls can be aborted before they resolve (e.g. to avoid race conditions in for instant search UIs). - `XMLHttpRequest` provides hooks for progress listeners for long running requests (e.g. file uploads). -- `XMLHttpRequest` is supported by all browsers, whereas `fetch()` is not supported by Internet Explorer, Safari and Android (non-Chromium). +- `XMLHttpRequest` is supported by all browsers, whereas `fetch()` is not supported by Internet Explorer and Android (non-Chromium). Currently, due to lack of browser support, `fetch()` typically requires a [polyfill](https://github.com/github/fetch), which is over 11kb uncompressed - nearly three times larger than Mithril's XHR module. From 35121b54202c81af694346b9cbd33109867cfd7d Mon Sep 17 00:00:00 2001 From: Gustavo Rodrigues Date: Fri, 30 Aug 2019 07:44:36 -0300 Subject: [PATCH 2/2] Update docs/request.md Co-Authored-By: Isiah Meadows --- docs/request.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/request.md b/docs/request.md index a280d0818..3fe2fb992 100644 --- a/docs/request.md +++ b/docs/request.md @@ -494,7 +494,7 @@ Mithril's `m.request` uses `XMLHttpRequest` instead of `fetch()` for a number of - `fetch` is not fully standardized yet, and may be subject to specification changes. - `XMLHttpRequest` calls can be aborted before they resolve (e.g. to avoid race conditions in for instant search UIs). - `XMLHttpRequest` provides hooks for progress listeners for long running requests (e.g. file uploads). -- `XMLHttpRequest` is supported by all browsers, whereas `fetch()` is not supported by Internet Explorer and Android (non-Chromium). +- `XMLHttpRequest` is supported by all browsers, whereas `fetch()` is not supported by Internet Explorer and older Android (prior to 5.0 Lollipop). Currently, due to lack of browser support, `fetch()` typically requires a [polyfill](https://github.com/github/fetch), which is over 11kb uncompressed - nearly three times larger than Mithril's XHR module.