-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: add importAssertion prettier plugin
- Loading branch information
Showing
9 changed files
with
51 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,11 @@ | ||
{ | ||
"extends": "./tsconfig.json", | ||
"include": [ | ||
"tests", | ||
"./src", | ||
"./typechain", | ||
"docgen-templates", | ||
"commitlint.config.js" | ||
"commitlint.config.js", | ||
"wagmi.config.ts", | ||
"src/environment.d.ts" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,5 @@ cache | |
coverage | ||
dist | ||
typechain | ||
src/config/abis/generated.ts | ||
subgraph-client/.graphqlclient |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,54 @@ | ||
import { defineConfig } from '@wagmi/cli' | ||
import { hardhat } from '@wagmi/cli/plugins' | ||
import poolLensArtifact from '@venusprotocol/isolated-pools/artifacts/contracts/Lens/PoolLens.sol/PoolLens.json' assert { type: "json"}; | ||
import diamondComptrollerArtifact from '@venusprotocol/venus-protocol/artifacts/contracts/Comptroller/Diamond/DiamondConsolidated.sol/DiamondConsolidated.json' assert { type: "json"}; | ||
import ilComptrollerArtifact from '@venusprotocol/isolated-pools/artifacts/contracts/Comptroller.sol/Comptroller.json' assert { type: "json"}; | ||
import coreVTokenArtifact from '@venusprotocol/venus-protocol/artifacts/contracts/Tokens/VTokens/VBep20Delegate.sol/VBep20Delegate.json' assert { type: "json"}; | ||
import protocolShareReserveArtifact from '@venusprotocol/protocol-reserve/artifacts/contracts/ProtocolReserve/ProtocolShareReserve.sol/ProtocolShareReserve.json' assert { type: "json"}; | ||
import vBnbAdminArtifact from '@venusprotocol/venus-protocol/artifacts/contracts/Admin/VBNBAdmin.sol/VBNBAdmin.json' assert { type: "json"}; | ||
import vBNB from '@venusprotocol/venus-protocol/artifacts/contracts/Admin/VBNBAdminStorage.sol/VTokenInterface.json' assert { type: "json"}; | ||
import ilComptrollerArtifact from "@venusprotocol/isolated-pools/artifacts/contracts/Comptroller.sol/Comptroller.json" assert { type: "json" }; | ||
import poolLensArtifact from "@venusprotocol/isolated-pools/artifacts/contracts/Lens/PoolLens.sol/PoolLens.json" assert { type: "json" }; | ||
import protocolShareReserveArtifact from "@venusprotocol/protocol-reserve/artifacts/contracts/ProtocolReserve/ProtocolShareReserve.sol/ProtocolShareReserve.json" assert { type: "json" }; | ||
import vBnbAdminArtifact from "@venusprotocol/venus-protocol/artifacts/contracts/Admin/VBNBAdmin.sol/VBNBAdmin.json" assert { type: "json" }; | ||
import vBNB from "@venusprotocol/venus-protocol/artifacts/contracts/Admin/VBNBAdminStorage.sol/VTokenInterface.json" assert { type: "json" }; | ||
import diamondComptrollerArtifact from "@venusprotocol/venus-protocol/artifacts/contracts/Comptroller/Diamond/DiamondConsolidated.sol/DiamondConsolidated.json" assert { type: "json" }; | ||
import coreVTokenArtifact from "@venusprotocol/venus-protocol/artifacts/contracts/Tokens/VTokens/VBep20Delegate.sol/VBep20Delegate.json" assert { type: "json" }; | ||
import { defineConfig } from "@wagmi/cli"; | ||
import { hardhat } from "@wagmi/cli/plugins"; | ||
import { Abi } from "abitype"; | ||
|
||
|
||
const getExternalContracts = async (): Promise<any> => [ | ||
const getExternalContracts = async (): Promise<{ name: string; abi: Abi }[]> => [ | ||
{ | ||
abi: poolLensArtifact.abi, | ||
name: 'PoolLens' | ||
abi: poolLensArtifact.abi as Abi, | ||
name: "PoolLens", | ||
}, | ||
{ | ||
abi: diamondComptrollerArtifact.abi, | ||
name: 'CoreComptroller' | ||
abi: diamondComptrollerArtifact.abi as Abi, | ||
name: "CoreComptroller", | ||
}, | ||
{ | ||
abi: ilComptrollerArtifact.abi, | ||
name: 'IlComptroller' | ||
abi: ilComptrollerArtifact.abi as Abi, | ||
name: "IlComptroller", | ||
}, | ||
{ | ||
abi: coreVTokenArtifact.abi, | ||
name: 'CoreVToken' | ||
abi: coreVTokenArtifact.abi as Abi, | ||
name: "CoreVToken", | ||
}, | ||
{ | ||
abi: protocolShareReserveArtifact.abi, | ||
name: 'ProtocolShareReserve' | ||
abi: protocolShareReserveArtifact.abi as Abi, | ||
name: "ProtocolShareReserve", | ||
}, | ||
{ | ||
abi: vBnbAdminArtifact.abi, | ||
name: 'VBnbAdmin' | ||
abi: vBnbAdminArtifact.abi as Abi, | ||
name: "VBnbAdmin", | ||
}, | ||
{ | ||
abi: vBNB.abi, | ||
name: 'vBNB' | ||
} | ||
] | ||
abi: vBNB.abi as Abi, | ||
name: "vBNB", | ||
}, | ||
]; | ||
|
||
export default defineConfig(async () => { | ||
const externalContracts = await getExternalContracts() | ||
const externalContracts = await getExternalContracts(); | ||
return { | ||
out: 'src/config/abis/generated.ts', | ||
out: "src/config/abis/generated.ts", | ||
contracts: externalContracts, | ||
plugins: [ | ||
hardhat({ | ||
project: '.', | ||
project: ".", | ||
}), | ||
], | ||
} | ||
}) | ||
}; | ||
}); |