Biconomy SDK
Search…
⌃K

Common Errors

List of common errors faced while integrating and how to debug

Polyfills Issue (React.js/Next.js)

Error example: 'crypto' not found...

CSS Issue with Social Login:

Error example: Social Login modal css not loading/breaking
Solution:
import "@biconomy/web3-auth/src/style.css"

Next js, document not found

Error: document not found while using Next.js
Solution: This happens because the code try to find the root element and create a div via DOM document, but if you are using server side Next.js then the lib not able to find the document. This fix is by rendering that component via next dynamics, An example code below and full code setup here.
import dynamic from "next/dynamic";
import { Suspense } from "react";
const Index = () => {
const SocialLoginDynamic = dynamic(
() => import("../components/SocialLogin").then((res) => res.default),
{
ssr: false,
}
);
return (
<div>
<Suspense fallback={<div>Loading...</div>}>
<SocialLoginDynamic />
</Suspense>
</div>
);
};
export default Index;