@usehall/bot-gate
Version:
React/Vue/Svelte components for conditionally rendering content based on bot detection with IP validation
9 lines (8 loc) • 383 B
TypeScript
export type SupportedBotName = 'googlebot' | 'bingbot' | 'oai-searchbot' | 'chatgpt-user' | 'gptbot' | 'perplexitybot' | 'perplexity-user' | 'applebot' | 'applebot-extended' | 'duckassistbot' | 'duckduckbot';
export interface BotGateProps {
userAgent: string;
ipAddress: string;
display: 'show' | 'hide';
role: 'bot' | 'user';
bots?: SupportedBotName[] | null;
}