Created
January 27, 2020 14:08
-
-
Save Hyllesen/2de994c877310ec6e354b7b76d506169 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
const request = require("request-promise"); | |
const cheerio = require("cheerio"); | |
async function main() { | |
const result = await request.get("http://codingwithstefan.com/table-example"); | |
const $ = cheerio.load(result); | |
$("body > table > tbody > tr > td").each((index, element) => { | |
console.log($(element).text()); | |
}); | |
} | |
main(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment