Created
May 12, 2017 13:08
-
-
Save TaizWeb/a9a6eb859c0075da378fd92d392565e1 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
// Originally made for https://nookipedia.com/wiki/Bugs/Animal_Crossing:_Wild_World | |
returnedObj = '[\n'; | |
function scrapeBugs() { | |
for (let i = 0; i < 56; i++) { | |
bugName = document.getElementById('mw-content-text').children[1].children[1].children[i].children[1].children[0].innerHTML; | |
returnedObj += `\t{'task_name': '${bugName}', 'task_complete': false},\n`; | |
} | |
returnedObj += '\n]'; | |
return returnedObj; | |
} | |
console.log(scrapeBugs()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment