Last active
July 28, 2021 16:40
-
-
Save vineethvijayan/1510ec927335d9d9b6afd8597eb9fd23 to your computer and use it in GitHub Desktop.
loop through the udemy elements
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
// loop through the udemy elements | |
var wholeList = document.getElementsByClassName('card--learning__details') | |
for (let item = 0; item < wholeList.length; item++) { | |
const element = wholeList[item]; | |
const courseLink = element.href | |
const courseName = element.children[0].children[0].innerText | |
console.log(courseName, '###' , courseLink) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment