Skip to content

Instantly share code, notes, and snippets.

@soner8
Last active May 22, 2018 15:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soner8/8c62765691cb2caa55de2daec5863f55 to your computer and use it in GitHub Desktop.
Save soner8/8c62765691cb2caa55de2daec5863f55 to your computer and use it in GitHub Desktop.
ES6 Partie 3
const address = {
city: "Lyon",
state: "FR",
zip: 69001
};
const sportList = ['Football', 'BasketBall']
const otherSportList = ['Boxe', 'Judo']
sportList.push(...otherSportList)
const display = (city = 'Caen', ...sportList) => {
console.log(`${city} ${sportList}`)
}
display(address.city, sportList);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment