Feat: validate domains are alive (and w/ CI)

This commit is contained in:
SukkaW
2024-11-05 23:39:45 +08:00
parent 7b6b14b1dc
commit 0bc901cdf8
9 changed files with 351 additions and 10 deletions

22
Build/mod.d.ts vendored Normal file
View File

@@ -0,0 +1,22 @@
import 'dns2';
declare module 'dns2' {
import DNS from 'dns2';
declare namespace DNS {
interface DoHClientOption {
/** @example dns.google.com */
dns: string,
/** @description whether to use HTTP or HTTPS */
http: boolean
}
export type DnsResolver<T = DnsResponse> = (name: string, type: PacketQuestion) => Promise<T>;
declare function DOHClient(opt: DoHClientOption): DnsResolver;
export type $DnsResponse = DnsResponse;
}
export = DNS;
}