From baec6f3271770e267db10cf5048e7fb7442870e1 Mon Sep 17 00:00:00 2001 From: SuperSimpleDev Date: Tue, 30 Apr 2024 13:15:34 -0400 Subject: [PATCH] 18e Solution --- 2-copy-of-code/lesson-18/lesson18.html | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/2-copy-of-code/lesson-18/lesson18.html b/2-copy-of-code/lesson-18/lesson18.html index cd857df..1c1c350 100644 --- a/2-copy-of-code/lesson-18/lesson18.html +++ b/2-copy-of-code/lesson-18/lesson18.html @@ -31,6 +31,7 @@ getGreeting(); */ + /* async function postGreeting() { const response = await fetch('https://supersimplebackend.dev/greeting', { method: 'POST', @@ -46,6 +47,14 @@ console.log(text); } postGreeting(); + */ + + async function getAmazon() { + const response = await fetch('https://amazon.com'); + const text = await response.text(); + console.log(text); + } + getAmazon(); \ No newline at end of file