UNPKG

inapp-spy

Version:
78 lines (73 loc) 1.93 kB
declare const appNameRegExps: { readonly messenger: { readonly regex: RegExp; readonly name: "Facebook Messenger"; }; readonly instagram: { readonly regex: RegExp; readonly name: "Instagram"; }; readonly facebook: { readonly regex: RegExp; readonly name: "Facebook"; }; readonly twitter: { readonly regex: RegExp; readonly name: "Twitter"; }; readonly line: { readonly regex: RegExp; readonly name: "Line"; }; readonly wechat: { readonly regex: RegExp; readonly name: "WeChat"; }; readonly threads: { readonly regex: RegExp; readonly name: "Threads"; }; readonly tiktok: { readonly regex: RegExp; readonly name: "TikTok"; }; readonly snapchat: { readonly regex: RegExp; readonly name: "Snapchat"; }; readonly linkedin: { readonly regex: RegExp; readonly name: "LinkedIn"; }; readonly gsa: { readonly regex: RegExp; readonly name: "Google Search App"; }; }; declare const appNameCustom: { readonly telegram: { readonly name: "Telegram"; }; }; type AppKey = keyof typeof appNameCustom | keyof typeof appNameRegExps | undefined; type AppName = (typeof appNameCustom)[keyof typeof appNameCustom]["name"] | (typeof appNameRegExps)[keyof typeof appNameRegExps]["name"] | undefined; type Skip = { appKey: AppKey; platform?: "apple" | "android"; }[]; declare const InAppSpy: (options?: { ua?: string; skip?: Skip; }) => { ua: string; isInApp: boolean; appKey: AppKey; appName: AppName; skipped: boolean; }; declare const SFSVCExperimental: ({ debug, maxVersion, maxTime, }?: { debug?: boolean; maxTime?: number; maxVersion?: string; }) => Promise<boolean>; export { SFSVCExperimental, InAppSpy as default };