-
-
Notifications
You must be signed in to change notification settings - Fork 35.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update step 18, 28, 38 hints for calorie counter project #54868
Comments
Similar issue was seen in step 28 where the hint said: while the instructions were again to create a function: And again, similar issue in step38 |
From Pyramid Generator
Here, Campers are introduced to the idea of functions as JavaScript code for a variable. |
Step 42 mentioned in the previous comment should be fixed. It should say: “The function declaration tells JavaScript that the name identifier is going to be a function.” My understanding is that a function is actually an object in js but I would be surprised if a js course starts telling learners to “declare an object called myFunction” instead of saying “declare a function called myFunction”. Edited… |
Step 42 should be a separate issue IMO. |
Here the updates for this issue updates step 18 hintsremove this hint and test You should declare a `cleanInputString` variable.
```js
assert.isDefined(cleanInputString);
``` the current second hint and test should say this instead You should declare a `cleanInputString` function.
```js
assert.isFunction(cleanInputString);
``` updates to step 28remove this hint and test You should declare an `isInvalidInput` variable.
```js
assert.isDefined(isInvalidInput)
``` updates to step 38 hintsremove this hint and test You should declare an `addEntry` variable.
```js
assert.isDefined(addEntry);
``` udpate the second hint to the following You should declare an `addEntry` function.
```js
assert.isFunction(addEntry);
``` |
Describe the Issue
The instructions in step 18 of the js beta to build a calorie counter says:
Start by declaring a cleanInputString function that takes a str parameter.
However if you misspell the function's name you receive this hint:
You should declare a cleanInputString variable.
I believe this message should be changed to say "function" instead of "variable"
Affected Page
https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures-v8/learn-form-validation-by-building-a-calorie-counter/step-18
Your code
Expected behavior
the hint should refer to a
function
not avariable
Screenshots
No response
System
N/A
Additional context
No response
The text was updated successfully, but these errors were encountered: