mirror of
https://github.com/hzrd149/nostrudel.git
synced 2025-09-22 15:19:47 +02:00
dont load ackee script when running locally
This commit is contained in:
@@ -20,13 +20,7 @@
|
|||||||
content="https://repository-images.githubusercontent.com/581644549/d5eec580-ba3d-41e8-87db-58c313bf3f45"
|
content="https://repository-images.githubusercontent.com/581644549/d5eec580-ba3d-41e8-87db-58c313bf3f45"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<script
|
%VITE_ANALYTICS_SCRIPT%
|
||||||
async
|
|
||||||
defer
|
|
||||||
src="https://ackee.nostrudel.ninja/tracker.js"
|
|
||||||
data-ackee-server="https://ackee.nostrudel.ninja"
|
|
||||||
data-ackee-domain-id="58b1c39f-43f9-422b-bc7d-06aff35e764e"
|
|
||||||
></script>
|
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="root"></div>
|
<div id="root"></div>
|
||||||
|
@@ -2,6 +2,17 @@ import { defineConfig } from "vite";
|
|||||||
import react from "@vitejs/plugin-react";
|
import react from "@vitejs/plugin-react";
|
||||||
import { VitePWA } from "vite-plugin-pwa";
|
import { VitePWA } from "vite-plugin-pwa";
|
||||||
|
|
||||||
|
const isProd = process.env.NODE_ENV === "production";
|
||||||
|
process.env.VITE_ANALYTICS_SCRIPT = isProd
|
||||||
|
? `
|
||||||
|
<script
|
||||||
|
async defer
|
||||||
|
src="https://ackee.nostrudel.ninja/tracker.js"
|
||||||
|
data-ackee-server="https://ackee.nostrudel.ninja"
|
||||||
|
data-ackee-domain-id="58b1c39f-43f9-422b-bc7d-06aff35e764e"
|
||||||
|
></script>`
|
||||||
|
: "";
|
||||||
|
|
||||||
// https://vitejs.dev/config/
|
// https://vitejs.dev/config/
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
base: process.env.VITE_BASE ?? "/",
|
base: process.env.VITE_BASE ?? "/",
|
||||||
|
Reference in New Issue
Block a user