rsshub
Version:
Make RSS Great Again!
49 lines (47 loc) • 1.47 kB
JavaScript
import { n as init_esm_shims, t as __dirname } from "./esm-shims-CzJ_djXG.mjs";
import "./config-C37vj7VH.mjs";
import { t as ViewType } from "./types-D84BRIt4.mjs";
import "./dist-BInvbO1W.mjs";
import "./logger-Czu8UMNd.mjs";
import "./ofetch-BIyrKU3Y.mjs";
import { t as parseDate } from "./parse-date-BrP7mxXf.mjs";
import "./helpers-DxBp0Pty.mjs";
import { t as art } from "./render-BQo6B4tL.mjs";
import { t as got_default } from "./got-KxxWdaxq.mjs";
import path from "node:path";
//#region lib/routes/cngal/weekly.ts
init_esm_shims();
const route = {
path: "/weekly",
categories: ["anime"],
view: ViewType.Articles,
example: "/cngal/weekly",
parameters: {},
features: {
requireConfig: false,
requirePuppeteer: false,
antiCrawler: false,
supportBT: false,
supportPodcast: false,
supportScihub: false
},
radar: [{ source: ["www.cngal.org/", "www.cngal.org/weeklynews"] }],
name: "每周速报",
maintainers: ["kmod-midori"],
handler,
url: "www.cngal.org/"
};
async function handler() {
return {
title: "CnGal - 每周速报",
link: "https://www.cngal.org/weeklynews",
item: (await got_default("https://api.cngal.org/api/news/GetWeeklyNewsOverview")).data.map((item) => ({
title: item.name,
description: art(path.join(__dirname, "templates/weekly-description-f2ac961c.art"), item),
pubDate: parseDate(item.lastEditTime),
link: `https://www.cngal.org/articles/index/${item.id}`
}))
};
}
//#endregion
export { route };