Skip to content

Clarify Explanation of Function Expressions in JavaScript Tutorial #3776

Open
@Skllkzm

Description

@Skllkzm

Description: The section of the tutorial discussing function expressions could benefit from a clearer distinction between Function Declarations and Function Expressions. Currently, the wording may cause confusion by implying that a Function Declaration creates a "variable" to hold the function name, which isn’t technically accurate.

Suggested Changes: In the tutorial, this line:

"The Function Declaration (1) creates the function and puts it into the variable named sayHi."

Might be more accurately phrased as:

"The Function Declaration (1) creates a function with the name sayHi. Unlike a Function Expression, this doesn’t involve a variable assignment."

This change would help learners understand that sayHi in this example is the function’s name from the declaration, rather than a variable containing the function reference.

Additional Context: I initially misunderstood this as creating a variable. I believe this clarification would prevent similar confusion for others. Thanks for considering this suggestion!

See screenshot attached
1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      close