From c8271d19a9f4a41032775e9248807d9acc88f534 Mon Sep 17 00:00:00 2001 From: kmmiio99o <164557248+kmmiio99o@users.noreply.github.com> Date: Tue, 10 Feb 2026 19:59:32 +0100 Subject: [PATCH] Update RPCPreview.tsx to wrap conditional renders and ensure consistent getStorage calls. --- RPCPreview.tsx | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 RPCPreview.tsx diff --git a/RPCPreview.tsx b/RPCPreview.tsx new file mode 100644 index 0000000..caa4a05 --- /dev/null +++ b/RPCPreview.tsx @@ -0,0 +1,23 @@ +// Updated RPCPreview.tsx to properly wrap all conditional renders and ensure getStorage is called consistently. + +import React from 'react'; +import { getStorage } from './storage'; + +const RPCPreview = () => { + const storageData = getStorage(); + + return ( +
+ {storageData ? ( +
+ {/* Conditional render based on storageData */} + {storageData.isAvailable ? : } +
+ ) : ( +
Loading...
+ )} +
+ ); +}; + +export default RPCPreview; \ No newline at end of file