Files
NapCatQQ/.pnpm-store/v3/files/ff/71e60bae9e1b52b0c07574098f2600f6b2b27c37485a4665ac354b8e18790ac632cf7c3059d84265db33455bee8d1da32ebec4d84cc2334a973061c70b0a4a
TanTan e311ca3275
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

34 lines
844 B
Plaintext

import type { Stats } from "node:fs";
import type { IncomingMessage, ServerResponse } from "node:http";
declare namespace sirv {
type Arrayable<T> = T | T[];
export type NextHandler = () => void | Promise<void>;
export type RequestHandler = (
req: IncomingMessage,
res: ServerResponse,
next?: NextHandler,
) => void;
export interface Options {
dev?: boolean;
etag?: boolean;
maxAge?: number;
immutable?: boolean;
single?: string | boolean;
ignores?: false | Arrayable<string | RegExp>;
extensions?: string[];
dotfiles?: boolean;
brotli?: boolean;
gzip?: boolean;
onNoMatch?: (req: IncomingMessage, res: ServerResponse) => void;
setHeaders?: (res: ServerResponse, pathname: string, stats: Stats) => void;
}
}
declare function sirv(dir?: string, opts?: sirv.Options): sirv.RequestHandler;
export = sirv;