UNPKG

rsshub

Version:
34 lines (32 loc) 923 B
import "./dist-Bog6z_OM.mjs"; import "./config-MQ-7ebJ_.mjs"; import "./logger-C4avouvV.mjs"; import { t as ofetch_default } from "./ofetch-DKl_Ma9g.mjs"; import { load } from "cheerio"; //#region lib/routes/cherrytimes/market.ts const route = { path: "/market", categories: ["new-media"], example: "/cherrytimes/market", name: "Market", maintainers: ["canonnizq"], handler: async () => { const $ = load(await ofetch_default("https://cherrytimes.it/en/tag/markets?page=1")); return { title: "Cherry Times - Market", link: "https://cherrytimes.it/en/tag/markets", item: $("div.post-container").toArray().map((item) => { const element = $(item); const a = element.find("a").eq(1); return { title: a.text(), link: a.attr("href"), description: element.find("p.excerpt").text(), category: element.find("a").last().text() }; }) }; } }; //#endregion export { route };