Skip to content
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

[V3] Implement new Concept Exercise: Function Expression and ES6 Arrow Function #955

Closed
shubhsk88 opened this issue Oct 22, 2020 · 2 comments

Comments

@shubhsk88
Copy link
Contributor

This issue describes how to declare the function expression and declaration with the ES6 Arrow function.

This issue describes how to implement the function concept exercise for the Javascript track.

Getting started

Please please please read the docs before starting. Posting PRs without reading these docs will be a lot more frustrating for you during the review cycle and exhaust Exercism's maintainers' time. So, before diving into the implementation, please read up on the following documents:

Please also watch the following video:

Goal

This exercise aims to tell the student about the declaration of function, arrow function.

For example:

  • function hello ( ) { }
  • let hello = function ( ) { }
  • const hello = ( ) => { }

Learning objectives

  • The student able to figure out the difference between function declaration and function expression.
  • The student able to know how the arrow function can be implemented and where to use it.
  • Explaining the definition of high order function

Out of scope

  • Closures
  • Use of arrow function in the context of this keyword;
  • Callbacks

Concepts

  • function declartions

Prerequisites

  • functions-intro
  • variables

After

  • Understanding of execution context of the function
  • Higher-order function
  • When to use function declarations or function expressions

Help

If you have any questions while implementing the exercise, please post the questions as comments on this issue.

@SleeplessByte
Copy link
Member

Cool!

I don't think higher order functions are in scope.

I think it will be hard to test for use of one of the variants, BUT we can write an analyzer to do that instead.

Interesting would be:

  • name of the function
  • binding of this (as well as other context such as arguments)

Since this is a hard concept to teach clearly, I would recommend writing up ideas in this issue first before commuting a lot of time to it. 🤗

@mikedamay mikedamay transferred this issue from exercism/v3 Jan 28, 2021
@mikedamay mikedamay changed the title [Javascript] Implement new Concept Exercise: Function Expression and ES6 Arrow Function [V3] Implement new Concept Exercise: Function Expression and ES6 Arrow Function Jan 28, 2021
@junedev
Copy link
Member

junedev commented Jul 29, 2021

I am closing this issue because we decided to cut the concepts/concept exercises differently. See #951 (comment) for details. Arrow functions will be combined with callbacks in one exercise and function expression are covered in the functions concept/concept exercise.

@junedev junedev closed this as completed Jul 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants