diff options
author | August Skare <post@augustskare.no> | 2018-10-26 15:59:10 +0800 |
---|---|---|
committer | August Skare <post@augustskare.no> | 2018-10-26 15:59:10 +0800 |
commit | 89e439c521aed35be72bee1094d8a431e5fc1d68 (patch) | |
tree | 8a05e838779785a65095df084e7266949bdb004e /packages/dev-tools-pages/ts/pages/Cov.tsx | |
parent | 0f97771d5ae728b10afd532bcb75a93ab66775e8 (diff) | |
download | dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar.gz dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar.bz2 dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar.lz dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar.xz dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.tar.zst dexon-sol-tools-89e439c521aed35be72bee1094d8a431e5fc1d68.zip |
update content in tabs
Diffstat (limited to 'packages/dev-tools-pages/ts/pages/Cov.tsx')
-rw-r--r-- | packages/dev-tools-pages/ts/pages/Cov.tsx | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/packages/dev-tools-pages/ts/pages/Cov.tsx b/packages/dev-tools-pages/ts/pages/Cov.tsx index 743b990df..4d8288219 100644 --- a/packages/dev-tools-pages/ts/pages/Cov.tsx +++ b/packages/dev-tools-pages/ts/pages/Cov.tsx @@ -84,8 +84,23 @@ function Cov() { const artifactAdapter = new SolCompilerArtifactAdapter(artifactsDir, contractsDir);`} </Code> </TabBlock> - <TabBlock title="Truffle">Truffle</TabBlock> - <TabBlock title="Custom">Custom</TabBlock> + <TabBlock title="Truffle"> + <Code language="javascript"> + {`import { TruffleArtifactAdapter } from '@0x/sol-trace'; + +const projectRoot = '.'; +const solcVersion = '0.4.24'; +const artifactAdapter = new TruffleArtifactAdapter(projectRoot, solcVersion);`} + </Code> + </TabBlock> + <TabBlock title="Custom"> + <Code language="javascript"> + {`import { AbstractArtifactAdapter } from '@0x/sol-trace'; + +class YourCustomArtifactsAdapter extends AbstractArtifactAdapter {...}; +const artifactAdapter = new YourCustomArtifactsAdapter(...);`} + </Code> + </TabBlock> </Tabs> <p> Now that we have an <InlineCode>artifactAdapter</InlineCode>, we can create a{' '} @@ -93,7 +108,7 @@ const artifactAdapter = new SolCompilerArtifactAdapter(artifactsDir, contractsDi </p> <Breakout> - <Code language="js"> + <Code language="javascript"> {`import { ProviderEngine, RpcSubprovider } from 'web3-provider-engine'; import { RevertTraceSubprovider } from '@0x/sol-cov'; |