[SOLVED] Issue with react & connecting

Hopefully someone can help me here, as I’ve really hit a wall:

added unity to react via react-unity-webgl it works, but upon hitting connect to connect with metamask I get this weird error. game works perfectly fine in standalone… anyone got any idea?

image

Component

import React from "react";
import { Unity, useUnityContext } from "react-unity-webgl";

const Mint = () => {
  const { unityProvider } = useUnityContext({
    loaderUrl: "../build/Test21.loader.js",
    dataUrl: "../build/Test21.data",
    frameworkUrl: "../build/Test21.framework.js",
    codeUrl: "../build/Test21.wasm",
  });
  return (
    <Unity
      unityProvider={unityProvider}
      style={{ width: 1000, height: 1000 }}
    />
  );
};

export default Mint;

What does your connect to MetaMask code look like? Does the rest of the game work normally?

fixed it can be closed. got actual help from the react author

1 Like

Can you explain here please how did you solve it