From a04c87e05f59e76ef772fc93377d64160920a21c Mon Sep 17 00:00:00 2001 From: RGHANILOO Date: Tue, 5 Mar 2024 08:49:00 +0000 Subject: [PATCH] chore(curriculum):add quote to text and string in Building a Date Formatter project (#53948) --- .../65388bbcbf6928b83fc424d1.md | 4 ++-- .../65388edfdf364fbb04e426f2.md | 6 +++--- .../65389a63d3b1d6c764c0e10e.md | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388bbcbf6928b83fc424d1.md b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388bbcbf6928b83fc424d1.md index d25abe69aef..3bfd3c7ad1d 100644 --- a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388bbcbf6928b83fc424d1.md +++ b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388bbcbf6928b83fc424d1.md @@ -15,7 +15,7 @@ element.addEventListener("change", () => { }); ``` -Attach the `addEventListener` method to the `dateOptionsSelectElement`. The first argument of the event listener should be the string `change` and the second argument should be an empty arrow function. +Attach the `addEventListener` method to the `dateOptionsSelectElement`. The first argument of the event listener should be the string `"change"` and the second argument should be an empty arrow function. # --hints-- @@ -25,7 +25,7 @@ You should attach the `addEventListener` method to the `dateOptionsSelectElement assert(code.match(/dateOptionsSelectElement\.addEventListener\s*\(/g)); ``` -Your event listener should listen for a `change` event. +Your event listener should listen for a `"change"` event. ```js assert(code.match(/dateOptionsSelectElement\.addEventListener\s*\(\s*('|")change\1/g)); diff --git a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388edfdf364fbb04e426f2.md b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388edfdf364fbb04e426f2.md index ea7c57f915e..64e3e0325ff 100644 --- a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388edfdf364fbb04e426f2.md +++ b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65388edfdf364fbb04e426f2.md @@ -9,7 +9,7 @@ dashedName: step-17 When the user chooses the `Year, Month, Day` option from the dropdown, the date format should reflect this choice. -To do this, you can add a `case` clause in the `switch` statement that checks for a match against the expression `expr`, followed by code to run if there's a match. Here's an example where the `case` clause checks that `expr` is equal to the string `case123`: +To do this, you can add a `case` clause in the `switch` statement that checks for a match against the expression `expr`, followed by code to run if there's a match. Here's an example where the `case` clause checks that `expr` is equal to the string `"case123"`: ```js switch (expr) { @@ -18,12 +18,12 @@ switch (expr) { } ``` -Add a `case` where the value is `yyyy-mm-dd`. Inside the `case`, set the text content of `currentDateParagraph` to the value of `formattedDate`. +Add a `case` where the value is `"yyyy-mm-dd"`. Inside the `case`, set the text content of `currentDateParagraph` to the value of `formattedDate`. # --hints-- -You should add a `case` where the condition is `yyyy-mm-dd`. Then set the `textContent` property of `currentDateParagraph` equal to `formattedDate`. +You should add a `case` where the condition is `"yyyy-mm-dd"`. Then set the `textContent` property of `currentDateParagraph` equal to `formattedDate`. ```js assert(code.match(/case\s*('|")yyyy-mm-dd\1\s*:\s*currentDateParagraph\.textContent\s*=\s*formattedDate/g)); diff --git a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65389a63d3b1d6c764c0e10e.md b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65389a63d3b1d6c764c0e10e.md index 94d48537b40..4990dd330a9 100644 --- a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65389a63d3b1d6c764c0e10e.md +++ b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-the-date-object-by-building-a-date-formatter/65389a63d3b1d6c764c0e10e.md @@ -7,13 +7,13 @@ dashedName: step-22 # --description-- -Add another `case` with the value `mm-dd-yyyy-h-mm`. Inside that `case`, set the text content of `currentDateParagraph` to empty template literals. +Add another `case` with the value `"mm-dd-yyyy-h-mm"`. Inside that `case`, set the text content of `currentDateParagraph` to empty template literals. Also, make sure to include a `break` statement to terminate the `switch` statement. # --hints-- -You should add a `case` where the condition is `mm-dd-yyyy-h-mm`, then set the `textContent` property of `currentDateParagraph` equal to empty template literals. +You should add a `case` where the condition is `"mm-dd-yyyy-h-mm"`, then set the `textContent` property of `currentDateParagraph` equal to empty template literals. ```js assert(code.match(/case\s*('|")mm-dd-yyyy-h-mm\1\s*:\s*currentDateParagraph\.textContent\s*=\s*``/g));