Skip to content

Commit 08f8c8a

Browse files
kapetan3sidCopilotgithub-actions[bot]nhussein11eshaben
authored
[Hardhat] Create compile, deploy, install and config pages (#1150)
* create compile, deploy and install and config pages * Update smart-contracts/dev-environments/hardhat/install-and-config.md Co-authored-by: Copilot <[email protected]> * Update smart-contracts/dev-environments/hardhat/deploy-a-contract.md Co-authored-by: Copilot <[email protected]> * Update smart-contracts/dev-environments/hardhat/compile-and-test.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update smart-contracts/dev-environments/hardhat/compile-and-test.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update smart-contracts/dev-environments/hardhat/compile-and-test.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update smart-contracts/dev-environments/hardhat/compile-and-test.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update smart-contracts/dev-environments/hardhat/compile-and-test.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Apply suggestion from @github-actions[bot] Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Refactor Hardhat docs from hardhat-polkadot to standard Hardhat - Update install-and-config.md to use standard Hardhat toolbox - Replace hardhat-polkadot init with standard hardhat init - Remove plugin upgrade section and PolkaVM-specific references - Update compile-and-test.md to use solc instead of resolc - Replace artifacts-pvm directory references with artifacts - Remove Substrate node and ETH-RPC adapter configuration - Update deploy-a-contract.md with inline standard Hardhat config - Delete obsolete hardhat-polkadot config snippet files * add install and config page * add compile and test page * add code snipped for local node * add deploy page fixes * Update smart-contracts/dev-environments/hardhat/install-and-config.md Co-authored-by: Copilot <[email protected]> * minor snippet fix * Apply suggestions from code review Co-authored-by: Copilot <[email protected]> * correct syntax issue * apply feedback * Apply suggestions from code review Co-authored-by: Nicolás Hussein <[email protected]> * Update smart-contracts/dev-environments/hardhat/deploy-a-contract.md Co-authored-by: Nicolás Hussein <[email protected]> * Update smart-contracts/dev-environments/hardhat/deploy-a-contract.md Co-authored-by: Nicolás Hussein <[email protected]> * Update smart-contracts/dev-environments/hardhat/deploy-a-contract.md Co-authored-by: Nicolás Hussein <[email protected]> * fix code snippet formatting * overhaul the dev env > hardhat section into a single page * remove old hardhat and foundry links * remove troubleshooting page * llms * fix links and llms --------- Co-authored-by: Copilot <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Nicolás Hussein <[email protected]> Co-authored-by: Erin Shaben <[email protected]>
1 parent ee3d9dd commit 08f8c8a

File tree

51 files changed

+5149
-7156
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+5149
-7156
lines changed

.ai/categories/basics.md

Lines changed: 359 additions & 387 deletions
Large diffs are not rendered by default.

.ai/categories/dapps.md

Lines changed: 362 additions & 390 deletions
Large diffs are not rendered by default.

.ai/categories/infrastructure.md

Lines changed: 359 additions & 387 deletions
Large diffs are not rendered by default.

.ai/categories/networks.md

Lines changed: 359 additions & 387 deletions
Large diffs are not rendered by default.

.ai/categories/parachains.md

Lines changed: 1010 additions & 443 deletions
Large diffs are not rendered by default.

.ai/categories/polkadot-protocol.md

Lines changed: 359 additions & 387 deletions
Large diffs are not rendered by default.

.ai/categories/smart-contracts.md

Lines changed: 580 additions & 1077 deletions
Large diffs are not rendered by default.

.ai/categories/tooling.md

Lines changed: 456 additions & 994 deletions
Large diffs are not rendered by default.

.ai/pages/smart-contracts-cookbook-dapps-zero-to-hero.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ This file defines the contract address, ABI, and functions to create a viem [con
352352

353353
## Create the Wallet Connection Component
354354

355-
Now, let's create a component to handle wallet connections. Create a new file called `components/WalletConnect.tsx`:
355+
Now, you can create a component to handle wallet connections. Create a new file called `components/WalletConnect.tsx`:
356356

357357
```typescript title="WalletConnect.tsx"
358358
"use client";
@@ -535,7 +535,7 @@ This component handles connecting to the wallet, switching networks if necessary
535535

536536
## Create the Read Contract Component
537537

538-
Now, let's create a component to read data from the contract. Create a file called `components/ReadContract.tsx`:
538+
Next, create a component to read data from the contract. Create a file called `components/ReadContract.tsx`:
539539

540540
```typescript title="ReadContract.tsx"
541541
'use client';
@@ -608,7 +608,7 @@ This component reads the `storedNumber` value from the contract and displays it
608608

609609
## Create the Write Contract Component
610610

611-
Finally, let's create a component that allows users to update the stored number. Create a file called `components/WriteContract.tsx`:
611+
Finally, create a component that allows users to update the stored number. Create a file called `components/WriteContract.tsx`:
612612

613613
```typescript title="WriteContract.tsx"
614614
"use client";

.ai/pages/smart-contracts-cookbook-eth-dapps-uniswap-v2.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,13 @@ Before starting, make sure you have:
1919

2020
- Node.js (v16.0.0 or later) and npm installed.
2121
- Basic understanding of Solidity and JavaScript.
22-
- Familiarity with [`hardhat-polkadot`](/smart-contracts/dev-environments/hardhat/get-started/){target=\_blank} development environment.
22+
- Familiarity with `hardhat-polkadot` development environment.
2323
- Some PAS test tokens to cover transaction fees (obtained from the [Polkadot faucet](https://faucet.polkadot.io/?parachain=1111){target=\_blank}).
2424
- Basic understanding of how AMMs and liquidity pools work.
2525

2626
## Set Up the Project
2727

28-
Let's start by cloning the Uniswap V2 project:
28+
Start by cloning the Uniswap V2 project:
2929

3030
1. Clone the Uniswap V2 repository:
3131

@@ -40,7 +40,7 @@ Let's start by cloning the Uniswap V2 project:
4040
npm install
4141
```
4242
43-
3. Update the `hardhat.config.js` file so the paths for the Substrate node and the ETH-RPC adapter match with the paths on your machine. For more info, check the [Testing your Contract](/smart-contracts/dev-environments/hardhat/compile-and-test/){target=\_blank} section in the Hardhat guide.
43+
3. Update the `hardhat.config.js` file so the paths for the Substrate node and the ETH-RPC adapter match with the paths on your machine:
4444
4545
```js title="hardhat.config.js"
4646
hardhat: {

0 commit comments

Comments
 (0)