mirror of
https://github.com/DIYgod/RSSHub.git
synced 2026-10-17 05:11:57 +08:00
cb0791cb41
* perf: use only one WASM alloc for xxhash * perf(deps): lazy load mercury-parser and use googleapis/youtube instead of heavy googleapis * perf(dx): lazy load dev registry speed up npm dev script * perf: close playwright browser on destroy * fix: show exception msg in prod * revert: "perf: use only one WASM alloc for xxhash" This reverts commit01ecdd48d0. * perf: use only one WASM alloc for xxhash * test: add claim for worker * fix: missing piece from8dd9c9a* feat: add namespace to the chunkfilename * fix: keep var naming
24 lines
569 B
TypeScript
24 lines
569 B
TypeScript
import type { RouteHandler } from '@hono/zod-openapi';
|
|
import { createRoute } from '@hono/zod-openapi';
|
|
|
|
import { getRadarRules } from './utils';
|
|
|
|
const route = createRoute({
|
|
method: 'get',
|
|
path: '/radar/rules',
|
|
description: 'All Radar rules grouped by domain',
|
|
tags: ['Radar'],
|
|
responses: {
|
|
200: {
|
|
description: 'Radar rules grouped by domain',
|
|
},
|
|
},
|
|
});
|
|
|
|
const handler: RouteHandler<typeof route> = async (ctx) => {
|
|
const rules = await getRadarRules();
|
|
return ctx.json(rules);
|
|
};
|
|
|
|
export { handler, route };
|