Skip to content

Commit 52f80a3

Browse files
authored
fix: missing semicolon (#1880)
<img width="1659" height="956" alt="Screenshot 2025-09-04 at 10-34-01 missing semicolon meme at DuckDuckGo" src="https://github.com/user-attachments/assets/d579ec5f-95fd-439e-8ecc-005ca6a9f08b" />
1 parent 63288f6 commit 52f80a3

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

sources/academy/webscraping/scraping_basics_javascript2/09_getting_links.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ async function exportCSV(data) {
186186
return await parser.parse(data).promise();
187187
}
188188

189-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
189+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
190190
const $ = await download(listingURL);
191191

192192
const data = $(".product-item").toArray().map(element => {
@@ -281,7 +281,7 @@ function parseProduct($productItem, baseURL) {
281281
Now we'll pass the base URL to the function in the main body of our program:
282282

283283
```js
284-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
284+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
285285
const $ = await download(listingURL);
286286

287287
const data = $(".product-item").toArray().map(element => {

sources/academy/webscraping/scraping_basics_javascript2/10_crawling.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ async function exportCSV(data) {
6464
return await parser.parse(data).promise();
6565
}
6666

67-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
67+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
6868
const $ = await download(listingURL);
6969

7070
const data = $(".product-item").toArray().map(element => {
@@ -133,7 +133,7 @@ In the `.map()` loop, we're already going through all the products. Let's expand
133133
First, we need to make the loop asynchronous so that we can use `await download()` for each product. We'll add the `async` keyword to the inner function and rename the collection to `promises`, since it will now store promises that resolve to items rather than the items themselves. We'll pass it to `await Promise.all()` to resolve all the promises and retrieve the actual items.
134134

135135
```js
136-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
136+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
137137
const $ = await download(listingURL);
138138

139139
// highlight-next-line
@@ -149,7 +149,7 @@ const data = await Promise.all(promises);
149149
The program behaves the same as before, but now the code is prepared to make HTTP requests from within the inner function. Let's do it:
150150

151151
```js
152-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
152+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
153153
const $ = await download(listingURL);
154154

155155
const promises = $(".product-item").toArray().map(async element => {

sources/academy/webscraping/scraping_basics_javascript2/11_scraping_variants.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ We loop over the variants using `.map()` method to create an array of item copie
103103
Let's adjust the loop so it returns a promise that resolves to an array of items instead of a single item. If a product has no variants, we'll return an array with a single item, setting `variantName` to `null`:
104104

105105
```js
106-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
106+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
107107
const $ = await download(listingURL);
108108

109109
const promises = $(".product-item").toArray().map(async element => {
@@ -282,7 +282,7 @@ function parseVariant($option) {
282282
}
283283
// highlight-end
284284

285-
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales"
285+
const listingURL = "https://warehouse-theme-metal.myshopify.com/collections/sales";
286286
const $ = await download(listingURL);
287287

288288
const promises = $(".product-item").toArray().map(async element => {

0 commit comments

Comments
 (0)