Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

Add support for offline lottie In air gapped, lotties won't load because the WASM player is fetched from CDN. This PR bundles the player so we can fetch it directly from file system

Maidul Islam6cbeb4ddf953
diff --git a/frontend/src/main.tsx b/frontend/src/main.tsx
index 779c21bd85..87b7682dd9 100644
--- a/frontend/src/main.tsx
+++ b/frontend/src/main.tsx
@@ -2,6 +2,8 @@ import { StrictMode } from "react";
import ReactDOM from "react-dom/client";
import { createRouter, RouterProvider } from "@tanstack/react-router";
import NProgress from "nprogress";
+import { setWasmUrl } from '@lottiefiles/dotlottie-react';
+import lottieWasmUrl from '@lottiefiles/dotlottie-web/dist/dotlottie-player.wasm?url';
import { ContentLoader } from "./components/v2";
import { queryClient } from "./hooks/api/reactQuery";
@@ -22,6 +24,9 @@ import "./translation";
// have a look at the Quick start guide
// for passing in lng and translations on init/
+// Configure Lottie player to use local WASM file
+setWasmUrl(lottieWasmUrl);
+
// Create a new router instance
NProgress.configure({ showSpinner: false });