@nekm/svelte-core 1.0.21 → 1.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -16,16 +16,20 @@
|
|
|
16
16
|
readonly productionDomain?: string | URL;
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
+
interface GoogleAnalyticsConfig {
|
|
20
|
+
readonly debug_mode?: boolean;
|
|
21
|
+
}
|
|
22
|
+
|
|
19
23
|
const { id, productionDomain }: GoogleAnalyticsProps = $props();
|
|
20
24
|
|
|
21
25
|
onMount(() => {
|
|
22
|
-
let config = {};
|
|
26
|
+
let config: GoogleAnalyticsConfig = { debug_mode: true };
|
|
23
27
|
|
|
24
28
|
if (productionDomain) {
|
|
25
29
|
const productionDomainStr = productionDomain instanceof URL ? productionDomain.hostname : productionDomain;
|
|
26
30
|
|
|
27
|
-
if (page.url.hostname
|
|
28
|
-
config = {
|
|
31
|
+
if (page.url.hostname === productionDomainStr) {
|
|
32
|
+
config = {};
|
|
29
33
|
}
|
|
30
34
|
}
|
|
31
35
|
|
package/package.json
CHANGED