Created
December 20, 2014 21:16
-
-
Save JRJurman/3167df797e3325d3de65 to your computer and use it in GitHub Desktop.
Pokemon Scrapping
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
| number = document.querySelector(".stats-footer").querySelector("span").textContent.split("/")[0]; | |
| name = document.querySelector("h1").textContent; | |
| type = document.querySelector(".card-basic-info").querySelector(".energy").className.substr(12); | |
| stgStr = document.querySelector(".card-type").querySelector("h2").textContent; | |
| stage = stgStr.substring(0, stgStr.length - 8); | |
| if (stage !== "Basic") { | |
| evolvesFrom = document.querySelector(".card-type").querySelector("h4").textContent.split("Evolves From:")[1].trim(); | |
| } | |
| hp = document.querySelector(".card-hp").textContent.substr(2); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment