fetch post title from reddit api
var redditJson = "https://www.reddit.com/r/javascript.json" var fetch = require('node-fetch') fetch(redditJson) .then(function(response) { return response.json() }).then(function(json) { console.log('r/javascript top posts:') json.data.children.forEach(function(post) { console.log(post.data.title) }) })