Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
selankon committed Oct 30, 2024
1 parent b9e1b48 commit f1cd5c5
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 85 deletions.
18 changes: 8 additions & 10 deletions src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,25 +1,23 @@
import { ColorModeScript } from '@chakra-ui/react'
import { ClientProvider } from '@vocdoni/chakra-components'
import { EnvOptions } from '@vocdoni/sdk'
import { Signer } from 'ethers'
import { useTranslation } from 'react-i18next'
import { useWalletClient } from 'wagmi'
import { VocdoniEnvironment } from '~constants'
import { translations } from '~i18n/components'
import { clientToSigner } from '~util/wagmi-adapters'
// import { clientToSigner } from '~util/wagmi-adapters'
import { RoutesProvider } from './router'

export const App = () => {
const { data } = useWalletClient()
// const { data } = useWalletClient()
const { t } = useTranslation()

let signer: Signer = {} as Signer
if (data) {
signer = clientToSigner(data)
}
//
// let signer: Signer = {} as Signer
// if (data) {
// signer = clientToSigner(data)
// }

return (
<ClientProvider env={VocdoniEnvironment as EnvOptions} signer={signer} locale={translations(t)}>
<ClientProvider env={VocdoniEnvironment as EnvOptions} locale={translations(t)}>
<RoutesProvider />
<ColorModeScript />
</ClientProvider>
Expand Down
72 changes: 25 additions & 47 deletions src/util/rainbowkit.ts
Original file line number Diff line number Diff line change
@@ -1,49 +1,27 @@
import { getDefaultConfig } from '@rainbow-me/rainbowkit'
import '@rainbow-me/rainbowkit/styles.css'
import {
arbitrum,
avalanche,
base,
bsc,
degen,
eos,
fantom,
gnosis,
goerli,
hardhat,
localhost,
mainnet,
optimism,
polygon,
polygonMumbai,
polygonZkEvm,
sepolia,
zkSync,
zora,
} from 'wagmi/chains'

export const config = getDefaultConfig({
appName: 'Vocdoni Voting Page',
projectId: 'b78ba61f132db687dc6ec6d61b7e34d5',
chains: [
arbitrum,
avalanche,
base,
bsc,
degen,
eos,
fantom,
gnosis,
goerli,
hardhat,
localhost,
mainnet,
optimism,
polygon,
polygonMumbai,
polygonZkEvm,
sepolia,
zkSync,
zora,
],
})
// export const config = getDefaultConfig({
// appName: 'Vocdoni Voting Page',
// projectId: 'b78ba61f132db687dc6ec6d61b7e34d5',
// chains: [
// arbitrum,
// avalanche,
// base,
// bsc,
// degen,
// eos,
// fantom,
// gnosis,
// goerli,
// hardhat,
// localhost,
// mainnet,
// optimism,
// polygon,
// polygonMumbai,
// polygonZkEvm,
// sepolia,
// zkSync,
// zora,
// ],
// })
22 changes: 0 additions & 22 deletions src/util/wagmi-adapters.ts

This file was deleted.

13 changes: 7 additions & 6 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
{
"extends": "./tsconfig.paths.json",
"compilerOptions": {
"target": "ESNext",
"useDefineForClassFields": true,
"lib": ["DOM", "DOM.Iterable", "ESNext"],
"target": "esnext",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"esModuleInterop": false,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"strict": false,
"forceConsistentCasingInFileNames": true,
"module": "ESNext",
"moduleResolution": "Node",
"noFallthroughCasesInSwitch": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"noEmit": true,
Expand Down

0 comments on commit f1cd5c5

Please sign in to comment.