Created
November 9, 2016 16:06
-
-
Save johnlahboo/b4df2be74ea9ecbfb0684ef3f0c67b7b to your computer and use it in GitHub Desktop.
This file contains 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
var express = require('express') | |
var app = express() | |
app.get('/footballPlayers', function(req, res) { | |
var json_string = {"players":[ | |
{"name":"Messi", "goals":8}, | |
{"name":"Ronaldo", "goals":22}, | |
{"name":"Costa", "goals":20}, | |
{"name":"Neymar", "goals":13}, | |
{"name":"Arabi", "goals":6}, | |
{"name":"Bale", "goals":3}, | |
{"name":"Toquero", "goals":0}]}; | |
res.json(json_string) | |
}) | |
app.listen(3000) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment