Skip to content

Commit

Permalink
test: #1231; splash google-bot check;
Browse files Browse the repository at this point in the history
  • Loading branch information
migbash committed May 2, 2023
1 parent 4acbf4d commit 39619c7
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/lib/components/_Splash_screen.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,12 @@
import { onMount } from 'svelte';
let show: boolean = true;
let isGoogleBot: boolean = false;
if (browser)
{
const isGoogleBot = /bot|google/i.test(navigator.userAgent)
isGoogleBot = /bot|google/i.test(navigator.userAgent)
show = !isGoogleBot
if (isGoogleBot)
{
alert("IS GOOGLE");
}
}
/**
Expand Down Expand Up @@ -48,6 +45,10 @@
COMPONENT HTML
=================== -->

<h1>
{isGoogleBot}
</h1>

{#if show}
<div
id="splash-screen">
Expand Down

0 comments on commit 39619c7

Please sign in to comment.