WIP: disabling absurd-sql when using Capacitor SQLite

This commit is contained in:
Matthew Raymer
2025-05-27 13:15:41 +00:00
parent 7b4f9d6556
commit f0d8fdf98c
5 changed files with 151 additions and 33 deletions

View File

@@ -1,7 +1,11 @@
// @ts-expect-error but not sure why it's not in there
import { initBackend } from "absurd-sql/dist/indexeddb-main-thread";
import { initializeApp } from "./main.common";
import "./registerServiceWorker"; // Web PWA support
// Only import service worker for web builds
if (process.env.VITE_PLATFORM !== 'electron' && process.env.VITE_PWA_ENABLED === 'true') {
import("./registerServiceWorker"); // Web PWA support
}
const app = initializeApp();