Skip to content

Commit

Permalink
fix import
Browse files Browse the repository at this point in the history
  • Loading branch information
chaitanyapotti committed Apr 27, 2023
1 parent 53cadd7 commit 3e21ae0
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
10 changes: 5 additions & 5 deletions demos/wagmi-nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
"@types/node": "18.15.11",
"@types/react": "18.0.31",
"@types/react-dom": "18.0.11",
"next": "13.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"typescript": "4.9.5",
"@web3auth/base": "^5.1.0",
"@web3auth/modal": "^5.1.1",
"@web3auth/openlogin-adapter": "^5.1.1",
"@web3auth/torus-wallet-connector-plugin": "^5.1.0",
"@web3auth/web3auth-wagmi-connector": "file:../../",
"@web3auth/web3auth-wagmi-connector": "file:../../web3auth-web3auth-wagmi-connector-3.0.1.tgz",
"next": "13.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"typescript": "4.9.5",
"wagmi": "^0.12.8"
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"build": "torus-scripts build",
"release": "torus-scripts release",
"lint": "eslint --fix 'src/**/*.ts'",
"prepack": "yarn run build",
"prepack": "npm run build",
"pre-commit": "lint-staged --cwd ."
},
"dependencies": {
Expand Down
4 changes: 3 additions & 1 deletion src/lib/connector.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Address, Connector, ConnectorData, normalizeChainId, UserRejectedRequestError } from "@wagmi/core";
import type { Chain } from "@wagmi/core/chains";
import { ADAPTER_STATUS, CHAIN_NAMESPACES, IWeb3Auth, SafeEventEmitterProvider, WALLET_ADAPTER_TYPE, WALLET_ADAPTERS } from "@web3auth/base";
import type { IWeb3Auth, SafeEventEmitterProvider, WALLET_ADAPTER_TYPE } from "@web3auth/base";
import * as pkg from "@web3auth/base";
import type { IWeb3AuthModal, ModalConfig } from "@web3auth/modal";
import type { OpenloginLoginParams } from "@web3auth/openlogin-adapter";
import { providers, Signer } from "ethers";
Expand All @@ -9,6 +10,7 @@ import log from "loglevel";
import type { Options } from "./interfaces";

const IS_SERVER = typeof window === "undefined";
const { ADAPTER_STATUS, CHAIN_NAMESPACES, WALLET_ADAPTERS } = pkg;

function isIWeb3AuthModal(obj: IWeb3Auth | IWeb3AuthModal): obj is IWeb3AuthModal {
return typeof (obj as IWeb3AuthModal).initModal !== "undefined";
Expand Down

0 comments on commit 3e21ae0

Please sign in to comment.