Created
April 3, 2018 18:11
-
-
Save LearningMaterial/0761e1065a43ef841ed5463680744ef3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const footballLeagues = [ | |
{ type: "english_premier_league", total_goal: 341, target: "English-player" }, | |
{ type: "english_premier", total_goal: 341, target: "English-player" }, | |
{ type: "bundesliga", total_goal: 341, target: "German-player" }, | |
{ type: "english_premier_league", total_goal: 341, target: "English-player" }, | |
{ type: "la_liga", total_goal: 411, target: "Spanish_player" }, | |
{ type: "la_liga", total_goal: 101, target: "Argentain_player" } | |
]; | |
const la_ligaDetail = footballLeagues | |
.filter(league => league.type === "la_liga") | |
.filter(league => league.target === "Argentain_player") | |
.map(league => league.total_goal); | |
console.log(la_ligaDetail); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment