rsshub
Version:
Make RSS Great Again!
39 lines (37 loc) • 1.1 kB
JavaScript
import "./dist-Bog6z_OM.mjs";
import "./config-MQ-7ebJ_.mjs";
import "./logger-C4avouvV.mjs";
import "./ofetch-DKl_Ma9g.mjs";
import "./parse-date-r5WDWHno.mjs";
import "./is-worker-DESPicPc.mjs";
import "./cache-SV6W5EPy.mjs";
import "./helpers-Bo4JQYdN.mjs";
import "./got-CO-ndVl2.mjs";
import { t as utils_default } from "./utils-BxQVWAud.mjs";
//#region lib/routes/sobooks/date.ts
const route = {
path: "/date/:date?",
categories: ["reading"],
example: "/sobooks/date/2020-11",
parameters: { date: "日期,见例子,默认为当前年月" },
features: {
requireConfig: false,
requirePuppeteer: false,
antiCrawler: false,
supportBT: false,
supportPodcast: false,
supportScihub: false
},
radar: [{
source: ["sobooks.net/:category"],
target: "/:category"
}],
name: "归档",
maintainers: ["nczitzk"],
handler
};
async function handler(ctx) {
return await utils_default(ctx, `books/date/${(ctx.req.param("date") ?? `${(/* @__PURE__ */ new Date()).getFullYear()}/${(/* @__PURE__ */ new Date()).getMonth()}`).replace("-", "/")}`);
}
//#endregion
export { route };