fix(source): producthunt items selector

This commit is contained in:
Ou 2024-11-03 01:00:39 +08:00
parent 08c0abeaf8
commit 8263dbff71

View File

@ -5,7 +5,7 @@ export default defineSource(async () => {
const baseURL = "https://www.producthunt.com/"
const html: any = await myFetch(baseURL)
const $ = cheerio.load(html)
const $main = $("[data-test^=post-item]")
const $main = $("[data-test=homepage-section-0] [data-test^=post-item]")
const news: NewsItem[] = []
$main.each((_, el) => {
const a = $(el).find("a").first()