fix(curriculum): Added description texts about spaces in step 154 #48160 (#48196)

* fix(curriculum):  Added description texts about spaces in step 154 #48160

* fix(curriculum): Added description texts about spaces in step 154 #48160

Used the text as described in  #48087 (comment).

* fix(curriculum): Added description texts about spaces in step 154 #48160

* Update curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-basic-javascript-by-building-a-role-playing-game/62aa226207f33d3ad4c6f546.md

Removed Space in front of Your, as to not confuse future contributors.

Co-authored-by: Ilenia <nethleen@gmail.com>

* Update curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-basic-javascript-by-building-a-role-playing-game/62aa226207f33d3ad4c6f546.md

Removed space warming text to make description less verbose.

Co-authored-by: Ilenia <nethleen@gmail.com>

Co-authored-by: Ilenia <nethleen@gmail.com>
This commit is contained in:
Hatim Zahid
2022-10-23 01:55:59 -07:00
committed by GitHub
parent 09778bd72e
commit 874651413a
@@ -7,7 +7,7 @@ dashedName: step-154
# --description--
Use the `+=` operator to add ` Your [weapon] breaks.` to the end of `text.innerText`, replacing `weapon` with the last item in the `inventory` array. You can get this last item by using `inventory.pop()`, which will remove the last item in the array AND return it so it appears in your string.
Use the `+=` operator to add `Your [weapon] breaks.`, with a space in front of `Your`, to the end of `text.innerText`. Replace `[weapon]` with the last item in the `inventory` array using `inventory.pop()`, which will remove the last item in the array AND return it so it appears in your string.
# --hints--
@@ -24,7 +24,7 @@ You should use the `pop` method on the `inventory` array.
assert.match(attack.toString(), /inventory\.pop\(\)/);
```
You should add the string " Your " to `text.innerText`. Remember that spacing matters.
You should add `Your`, with a space before and after it, to `text.innerText`.
```js
assert.match(attack.toString(), /text\.innerText\s*\+=\s*('|")\sYour\s\1/);
@@ -37,7 +37,7 @@ console.log(attack.toString());
assert.match(attack.toString(), /text\.innerText\s*\+=\s*('|")\sYour\s\1\s*\+\s*inventory\.pop\(\)/);
```
You should add ` breaks.` to the ` "Your " + inventory.pop()` string.
You should add `breaks.`, with a space in front of it, to the end of your string.
```js
assert.match(attack.toString(), /text\.innerText\s*\+=\s*('|")\sYour\s\1\s*\+\s*inventory\.pop\(\)\s*\+\s*('|")\sbreaks\.\2/);