From e845b5f215ae145f120eb80cac2a6927fb3d5098 Mon Sep 17 00:00:00 2001 From: Cristian Wang <55093425+cristian-wang@users.noreply.github.com> Date: Wed, 9 Sep 2020 18:03:33 +0200 Subject: [PATCH] Update article.md Hi guys, I looked at your article to solve my CORS issue but it didn't work. So eventually I found a question on StackOverflow that explained in order to make things work properly, I needed to add also "Access-Control-Allow-Origin: https://javascript.info" to the preflight response. Did anyone have the same issue? If so, we need to update the article in order to save the time of future readers :) StackOverflow question: https://stackoverflow.com/questions/42558221/how-to-cors-enable-apache-web-server-including-preflight-and-custom-headers --- 5-network/05-fetch-crossorigin/article.md | 1 + 1 file changed, 1 insertion(+) diff --git a/5-network/05-fetch-crossorigin/article.md b/5-network/05-fetch-crossorigin/article.md index 31fb0b8b..ba46bc49 100644 --- a/5-network/05-fetch-crossorigin/article.md +++ b/5-network/05-fetch-crossorigin/article.md @@ -259,6 +259,7 @@ Access-Control-Request-Headers: Content-Type,API-Key ### Step 2 (preflight response) The server should respond with status 200 and headers: +- `Access-Control-Allow-Origin: https://javascript.info` - `Access-Control-Allow-Methods: PATCH` - `Access-Control-Allow-Headers: Content-Type,API-Key`.