From 511b90510a5821073ce3b9f499186a3b3d7bc589 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sun, 8 Mar 2026 23:05:32 -0700 Subject: register Hce capacitor plugin on JS side --- src/routes/(app)/fund/[id]/+page.svelte | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/routes/(app)/fund/[id]/+page.svelte b/src/routes/(app)/fund/[id]/+page.svelte index 254e6d31..14586701 100644 --- a/src/routes/(app)/fund/[id]/+page.svelte +++ b/src/routes/(app)/fund/[id]/+page.svelte @@ -15,6 +15,9 @@ import { t } from "$lib/translations"; import { copy, sats, loc, post } from "$lib/utils"; import { loginRedirect } from "$lib/store"; + import { registerPlugin } from "@capacitor/core"; + + const Hce = (window as any).Capacitor ? registerPlugin("Hce") : null; let { data }: any = $props(); @@ -33,7 +36,6 @@ let amountFiat = $derived(parseFloat(((amount * rate) / sats).toFixed(2))); let hceActive = $state(false); - const Hce = (window as any).Capacitor?.Plugins?.Hce; $effect(() => { $loginRedirect = $page.url.pathname; -- cgit v1.2.3