Using dev from environment
All checks were successful
ci/woodpecker/push/build Pipeline was successful
All checks were successful
ci/woodpecker/push/build Pipeline was successful
This commit is contained in:
parent
9012bb96d6
commit
aeaec1c3d2
1 changed files with 3 additions and 2 deletions
|
@ -3,11 +3,12 @@
|
||||||
import Toast from '$lib/components/Toast.svelte';
|
import Toast from '$lib/components/Toast.svelte';
|
||||||
import { onMount } from 'svelte';
|
import { onMount } from 'svelte';
|
||||||
import { onNavigate } from '$app/navigation';
|
import { onNavigate } from '$app/navigation';
|
||||||
|
import { dev } from '$app/environment';
|
||||||
|
|
||||||
let node: HTMLElement;
|
let node: HTMLElement;
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
if(import.meta.env.DEV) return;
|
if(dev) return;
|
||||||
|
|
||||||
if ('serviceWorker' in navigator) {
|
if ('serviceWorker' in navigator) {
|
||||||
addEventListener('load', function () {
|
addEventListener('load', function () {
|
||||||
|
|
Loading…
Reference in a new issue