Skip to content

Commit

Permalink
Merge pull request #100 from thuongtruong1009/es6
Browse files Browse the repository at this point in the history
feat: add lession write-arrow-functions-with-parameters
  • Loading branch information
thuongtruong1009 authored Sep 11, 2022
2 parents d5ca05c + 30f74b1 commit 00c061e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ES6/07_write-arrow-functions-with-parameters.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
const myConcat = (arr1, arr2) => arr1.concat(arr2);


console.log(myConcat([1, 2], [3, 4, 5]));
5 changes: 5 additions & 0 deletions ES6/08_set-default-parameters-for-your-functions.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// Only change code below this line
const increment = (number, value = 1) => number + value;
console.log(increment(5, 2));
console.log(increment(5));
// Only change code above this line

0 comments on commit 00c061e

Please sign in to comment.