diff --git a/src/app/Marine2/components/views/DiagnosticsView.tsx b/src/app/Marine2/components/views/DiagnosticsView.tsx index 8daf98e2..a0e987a9 100644 --- a/src/app/Marine2/components/views/DiagnosticsView.tsx +++ b/src/app/Marine2/components/views/DiagnosticsView.tsx @@ -69,7 +69,19 @@ const getDeviceDiagnostics = (windowSize: { width?: number; height?: number }) = property: translate("diagnostics.device.viewportHeight"), value: (windowSize.height ?? window.innerHeight) + "px", }, + { + property: translate("diagnostics.device.isWebAssemblySupported"), + value: `${checkIfWebAssemblyIsSupported()}`, + }, ] } +const checkIfWebAssemblyIsSupported = () => { + // Check for WebAssembly presence + if (typeof WebAssembly === "object" && typeof WebAssembly.instantiate === "function") { + return true + } + return false +} + export default observer(DiagnosticsView) diff --git a/src/app/locales/languages/en.json b/src/app/locales/languages/en.json index d92662d8..bdebefd6 100644 --- a/src/app/locales/languages/en.json +++ b/src/app/locales/languages/en.json @@ -116,7 +116,8 @@ "device": "Device", "userAgent": "User agent", "viewportHeight": "Viewport height", - "viewportWidth": "Viewport width" + "viewportWidth": "Viewport width", + "isWebAssemblySupported": "WebAssembly supported" }, "diagnostics": "Diagnostics" },