Make ESLint Happy

This commit is contained in:
SukkaW
2023-12-03 02:04:09 +08:00
parent 34ef0e58ff
commit d4ff4c5b2d
36 changed files with 136 additions and 140 deletions

32
Build/mod.d.ts vendored
View File

@@ -2,33 +2,33 @@ declare module 'gorhill-publicsuffixlist' {
type Selfie =
| string
| {
magic: number;
buf32: number[];
};
magic: number,
buf32: number[]
};
interface Decoder {
decode: (bufferStr: string, buffer: ArrayBuffer) => void;
decodeSize: (bufferStr: string) => number;
decode: (bufferStr: string, buffer: ArrayBuffer) => void,
decodeSize: (bufferStr: string) => number
}
interface Encoder {
encode: (buffer: ArrayBuffer, length: number) => string;
encode: (buffer: ArrayBuffer, length: number) => string
}
export interface PublicSuffixList {
version: string;
version: string,
parse(text: string, toAscii: (input: string) => string): void;
parse(text: string, toAscii: (input: string) => string): void,
getPublicSuffix(hostname: string): string;
getDomain(hostname: string): string;
getPublicSuffix(hostname: string): string,
getDomain(hostname: string): string,
suffixInPSL(hostname: string): boolean;
suffixInPSL(hostname: string): boolean,
toSelfie(encoder?: null | Encoder): Selfie;
fromSelfie(selfie: Selfie, decoder?: null | Decoder): boolean;
toSelfie(encoder?: null | Encoder): Selfie,
fromSelfie(selfie: Selfie, decoder?: null | Decoder): boolean,
enableWASM(options?: {
customFetch?: null | ((url: URL) => Promise<Blob>);
}): Promise<boolean>;
disableWASM(): Promise<boolean>;
customFetch?: null | ((url: URL) => Promise<Blob>)
}): Promise<boolean>,
disableWASM(): Promise<boolean>
}
const psl: PublicSuffixList;