I am trying to extract all the download links from the HTML source provided below:
https://i.sstatic.net/CvEMF.png
Below is the code I am currently using:
export const getSingleMusic = async (url) => {
const html = await getHtml(url)
const $ = cheerio.load(html)
const downloadSection = $('#mt-modal-download .col-4')
downloadSection.each((i, elem) => {
console.log($(elem).find('a').html())
})
}
However, the output I am getting is different:
https://i.sstatic.net/GFpiB.png
Can someone please guide me on how to correctly select the download links?